Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error when starting up the repo #7

Open
karkir0003 opened this issue Dec 24, 2023 · 2 comments
Open

error when starting up the repo #7

karkir0003 opened this issue Dec 24, 2023 · 2 comments

Comments

@karkir0003
Copy link

hey @ChangoMan, hope you are doing well. I'm getting the below error message when starting up the nextjs-starter-dimension repo using the readme.md instructins.

error message:

 ✓ Ready in 23.7s
 ○ Compiling / ...
   Using external babel configuration from /mnt/c/Users/karki/OneDrive/Desktop/karthik-personal-website/.babelrc
 ⨯ ./node_modules/next/dist/client/dev/on-demand-entries-client.js
Error: Failed to resolve "@babel/runtime/regenerator" 

this is my package.json (had to modify the next version and sass version based on stackoverflow threads and documentation)

{
  "name": "nextjs-dimension",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "dev": "next",
    "build": "next build",
    "start": "next start",
    "export": "next build && next export"
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "dependencies": {
    "@fortawesome/fontawesome": "*",
    "@fortawesome/fontawesome-free-brands": "*",
    "@fortawesome/fontawesome-free-regular": "*",
    "@fortawesome/react-fontawesome": "*",
    "autoprefixer": "^9.1.5",
    "babel-plugin-module-resolver": "^3.1.1",
    "babel-plugin-wrap-in-js": "^1.1.1",
    "babel-runtime": "^6.26.0",
    "glob": "^7.1.3",
    "next": "^14.0.0",
    "postcss-easy-import": "^3.0.0",
    "postcss-loader": "^3.0.0",
    "raw-loader": "^0.5.1",
    "react": "^18.2.0",
    "react-dom": "^18.2.0",
    "sass": "^1.22.10",
    "sass-loader": "^7.2.0"
  }
}

I'm wondering if you are able to push a fix to the starter template with the updated versions and needed dependencies ASAP? This is blocking me from migrating my personal website on vanilla html/css to next.js

@karkir0003
Copy link
Author

karkir0003 commented Dec 24, 2023

@ChangoMan I was able to get some sort of "hacky fix working" here. Your starter template was very helpful as a launch point for my use case. However, I strongly, strongly recommend that updates be made to this template since I noticed several things that were outdated including but not limited to:

  • The template uses next js v7, but to my knowledge v14 is preferred due to these docs. That could change very soon, but it's good to update the next version in package.json
  • The paradigm of React being used is class components. However, React docs really recommend functional components. We should refactor accordingly
  • I noticed that a few dependencies were missing regarding fontawesome as seen here
  • Correction to sass and sass-loader version here.
  • The import for FontAwesomeIcon is incorrect. I think that {FontAwesomeIcon} is needed (including curly braces) as per the docs
  • We should also refactor the article ids of About, Contact, Work etc into separate react components to make extensibility easier for other's use cases

I and the community would really appreciate it if you could make these updates to the original template for easier extensibility. Thanks for your help :)

@karkir0003
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant