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

freshSeedfunction

A new seed for something nobody asked for by number, drawn from Math.random.

Import it

import { freshSeed } from "@johnmorrisdotca/tane";

Definition

function freshSeed(options?: DrawSeedOptions): number

Parameters

NameTypeDescription
options (optional)DrawSeedOptions

Seed-range options, including the upper bound and reserved blocks.

Returns

number

A new seed for something nobody asked for by number, drawn from Math.random.

Examples

import { freshSeed, isSeed } from "@johnmorrisdotca/tane";

console.log(isSeed(freshSeed()));
true

What it prints (run when this page was built)

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