tedspare / hexle

Wordle for color hex codes. Guess the hex in six tries.
https://hexle-delta.vercel.app
1 stars 0 forks source link

Color should be the same for all users daily and not reset on refresh #3

Open DexterStorey opened 2 years ago

DexterStorey commented 2 years ago

Obviously we would need to do this for prod assuming we follow the wordl features with win/loss metrics daily and so we don't need to fix this until we iron out the game mechanic.

DexterStorey commented 2 years ago

Was thinking of ways to do this without a backend -> We can make SSR edge function that uses a private key to encode the date into a sudo random but globally similar hex (I think you mentioned something like this @tedspare)

tedspare commented 2 years ago

I like it, let's encode the day's UTC time (or some non-Eurocentric timezone 🖕🇬🇧) to set a global hex per day

What do you think about keeping the hex random in dev?

DexterStorey commented 2 years ago

Ya I'll make this and I'll pass an env var RANDOM=true so we can just change it in vercel for preview branches or a dev branch

DexterStorey commented 2 years ago

We should export like dev.DOMAIN or test.DOMAIN as a randomized branch for review features and practice

tedspare commented 1 year ago

We should export like dev.DOMAIN or test.DOMAIN as a randomized branch for review features and practice

What do you mean?

DexterStorey commented 1 year ago

We should export like dev.DOMAIN or test.DOMAIN as a randomized branch for review features and practice

What do you mean?

we can map subdomains on vercel to sync with branches - and have dedicated env vars for these - so then we could have a test branch that passes the random env variable at the subdomain test. and then it will be random only on that subdomain