Reference · Native level collections
STORIESconstant
The stories, one to a level.
Import it
import { STORIES } from "@johnmorrisdotca/karakuri/levels";
Definition
const STORIES: readonly Story[] = [
{
stages: [
{ problem: "rain", tools: ["umbrella", "sunglasses"], right: 0 },
{ problem: "puddle", tools: ["sandals", "boots"], right: 1 },
{ problem: "door", tools: ["key", "balloon"], right: 0 },
],
},
{
stages: [
{ problem: "dark", tools: ["spoon", "flashlight"], right: 1 },
{ problem: "gap", tools: ["plank", "pillow"], right: 0 },
{ problem: "bear", tools: ["ball", "honey"], right: 1 },
],
},
{
stages: [
{ problem: "snow", tools: ["shovel", "kite"], right: 0 },
{ problem: "wind", tools: ["sunhat", "scarf"], right: 1 },
{ problem: "hill", tools: ["sandals", "sled"], right: 1 },
],
},
{
stages: [
{ problem: "sea", tools: ["raft", "ball"], right: 0 },
{ problem: "treasure", tools: ["sandwich", "map"], right: 1 },
{ problem: "chest", tools: ["spoon", "key"], right: 1 },
],
},
]
Examples
import { STORIES } from "@johnmorrisdotca/karakuri/levels";
import { length } from "@johnmorrisdotca/karakuri/physics";
console.log(STORIES.length);4What it prints (run when this page was built)