UNPKG

ts-hashlife

Version:

Efficient TypeScript implementation of HashLife, an optimized algorithm for simulating Conway's Game of Life with memoization and quadtree-based compression.

30 lines (25 loc) 555 B
import { LifeUniverse, TreeNode } from "./life-universe"; import { LifeCanvasDrawer } from "./draw"; import { formats, Result, Pattern } from "./formats"; import { load_macrocell } from "./macrocell"; import EventBus, { EventMap } from "./event-bus"; import Game from "./hash-life"; const HashLife = { EventBus, Game, LifeUniverse, TreeNode, LifeCanvasDrawer, formats, load_macrocell, }; export { // Core components EventBus, Game as HashLife, // Types type Result, type Pattern, type EventMap, }; export default HashLife;