javascript – ReferenceError: React is not defined – Migrating from CRA to Vite and NX

I’m currently in the process of migrating a create-react-app (CRA-v4) monorepo Webpack setup to an NX Monorepo powered by vite. I’m currently stuck in trying to figure out how to solve the typical Uncaught ReferenceError: React is not defined Which happens whenever a file doesn’t import React directly, but has a named import from it, … Read more

javascript – index.html:121 Uncaught ReferenceError: (function) is not defined at HTMLButtonElement.onclick(

We are trying to make a memory game but we are getting an error on our functions: startGame, imgClick, etc. The cards are supposed to shuffle at random when we press the start button. We are getting images from firebase storage and use an array of strings to shuffel their position in our game. when … Read more