Finally I completed my Game of ife!
It was one of the most challenging projects for me!I have made using react only.Please give your feedbacks.
Niow I have one react project left and I am confused whether I should learn Redux now or left it for sometime in futureā¦because I have a lot of pressure to get job and I want to complete Freecodecamp curriculum as soon as possible!
I made it with React onlyā¦ Definitely ran into some issues where Redux/ImmutableJS would have been helpful. Kept managing to mutate my grid and it got messy, but I got it together eventuallyā¦ If anyone has any thoughts, please feel freeā¦ Love the feedback.
Right, thanks for pointing those out. Iāve fixed those now, but am just learning about requestAnimationFrameā¦ Itāll take me a little while to refactor with that in mind, but it seems like a much better option. Thanks for pointing that out!
Although itās not required, I would suggest trying to see if you can make the app able to have userās input while itās being generate (to be more interactive), as well have the board not restricted to its boundaries ( I noticed the behavior is different close the boundaries).
Thank you SO MUCH for the requestAnimationFrame adviceā¦ I read up on it, and it was so easy to switch it over from setInterval, and the difference is likeā¦ night and day. Itās awesome!
Total neophyte question here but I have not yet been able to figure this out: In general, what ātriggersā the grid to make the next change? How do you get the thing to ārunā?
When I wrote stuff like this in Javascript there was usually a self-referencing function that repeated itself every tenth of a second or so. But how is this done in React?
Mine actually uses React conceptsā¦ Imagine my surprise when I finished and checked out the code of the example project and itās mostly jQuery, lol.
Still could use some (any) optimization, but seems to be one of the faster implementations Iāve seen on CodePen. Mostly because it uses canvas. If anyone reading this hasnāt started this project - use canvas for your board! The DOM isnāt made for this sort of thing!
Are you trying to initiate re-render when you first open the game, nothingās happening at first, there just is a randomly populated field, and you click a white or green cell?