Versions
- Open: VersionChanges from v1 to v2+3-0export function sort(recipes: Map<string, Recipe>, materials: Material[]) {const have = new Set(materials.map((m) => m.name));⦚ 12 unchanged lines ⦚import { Material } from "https://esm.town/v/tmcw/Material";import { Recipe } from "https://esm.town/v/tmcw/Recipe";export function sort(recipes: Map<string, Recipe>, materials: Material[]) {const have = new Set(materials.map((m) => m.name));⦚ 12 unchanged lines ⦚
- Open: VersionChanges from v0 to v1+13-3
import _ from "npm:lodash-es";let numbers = _.range(10);export const untitled_bronzeSpider = numbers.map(n => n * 2);export function sort(recipes: Map<string, Recipe>, materials: Material[]) {const have = new Set(materials.map((m) => m.name));return Array.from(recipes.values()).map((recipe) => {return {recipe,weight: recipe.ingredients.filter((ingredient) => {return have.has(ingredient.material.name);}).length,};}).sort((a, b) => {return b.weight - a.weight;}).map((r) => r.recipe);} - Open: Version+4-0import _ from "npm:lodash-es";let numbers = _.range(10);export const untitled_bronzeSpider = numbers.map(n => n * 2);
Updated: November 16, 2023