nedredmond/a-maze

write stores to hash to build initial state from query param

Opened this issue · 1 comments

Hash a maze object to rebuild a specific maze. No need to keep random seeds-- we can just encode/decode the maze object (which contains width, height, and cell data).

Ran into some complications hashing and rebuilding state on initialization without it getting overwritten immediately. Svelte doesn't have built-in lifecycle methods that other frameworks do IRT first render.

Next thing to try:
Just keep a boolean firstRender that gets flipped by Brick Road's maze builder function.