Skip to the content

Tane種

Reproduce numbers from a seed, shuffle or pick items, share a daily puzzle and resume a saved stream.

Tane means seed in Japanese. About the name

Contents

Reference · Streams, draws and seeds

Steptype

One draw and the state after it, for code that keeps the state itself (in a database row, say).

Import it

import type { Step } from "@johnmorrisdotca/tane";

Definition

type Step = {
    readonly value: number;
    readonly state: number;
};

Members

NameTypeDescription
valuenumber
statenumber

Examples

import type { Step } from "@johnmorrisdotca/tane";
import { step } from "@johnmorrisdotca/tane";

const value: Step = step(42);
console.log(value.state);
1831565855

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/tane 1.3.0.