Is there another way to do this?

I want to generate a random word, when the users enter the site I want it to generate a random word, then generate the grid.

The way I thought to do this was to use an IIFE asynchronous, but it takes a few milliseconds to generate the first grid.

Code:
https://github.com/LeonCelestino/Wordle-Game/blob/main/assets/scripts/index.js
Livesite:
https://codepen.io/leoncelestino/pen/wvObBax
GitHub
A wordle game. Contribute to LeonCelestino/Wordle-Game development by creating an account on GitHub.
Wordle-Game/assets/scripts/index.js at main · LeonCelestino/Wordle-...
Was this page helpful?