Npm run develop Strapi admin panel console error: regeneratorRuntime

System Information
  • Strapi Version: 4.0.4
  • Operating System: Windows 10
  • Database: sqlite
  • Node Version: 18.12.1
  • NPM Version: N/A
  • Yarn Version: N/A

I have a project that I created using the command npx create-strapi-app backend

I have recently tried to execute the command npm run develop to start the server at http://localhost:1337/admin.

When I visit this address, the webpage is blank where usually there would be a login component. When I look at the Chrome console, I see this error:

Uncaught ReferenceError: regeneratorRuntime is not defined
at main.d567afea.js:2:1200335
at 423 (main.d567afea.js:2:1201227)
at e (main.d567afea.js:2:1207306)
at 1261 (main.d567afea.js:2:1182278)
at e (main.d567afea.js:2:1207306)
at 9321 (main.d567afea.js:2:1191843)
at e (main.d567afea.js:2:1207306)
at main.d567afea.js:2:1207332
at 94344 (main.d567afea.js:2:1207349)
at s (runtime~main.5bbf095b.js:1:141)

Can someone help please. Thanks.

So a few things you can try.

  1. Go into the backend folder and do npm install again just to make sure it’s all installed
  2. Delete .cache and build folder
  3. Execute npm run develop

See if this fixes it.

I have tried this and I get the same console error and nothing loads in http://localhost:1337/admin

Uncaught ReferenceError: regeneratorRuntime is not defined
at main.6c19bc94.js:12501:85105
at 423 (main.6c19bc94.js:12501:86003)
at e (main.6c19bc94.js:12501:92090)
at 1261 (main.6c19bc94.js:12501:67048)
at e (main.6c19bc94.js:12501:92090)
at 9321 (main.6c19bc94.js:12501:76613)
at e (main.6c19bc94.js:12501:92090)
at main.6c19bc94.js:12501:92116
at main.6c19bc94.js:12501:37
at 94344 (main.6c19bc94.js:12501:1603)

I had to downgrade Node to LTS version 16.19.0. It then installed npm v8.19.3. Previously I had the latest version of Node 18.x.x

Use guide to downgrade: NVM for Windows – How to Download and Install Node Version Manager in Windows 10

Then when I ran npx create-strapi-app@latest backend --quickstart, it ran successfully and the Strapi admin page loaded in localhost server.