hydrogen: npm run dev failing with codegen
What is the location of your example repository?
No response
Which package or tool is having this issue?
Hydrogen
What version of that package or tool are you using?
2023.10.2
What version of Remix are you using?
2.1.0
Steps to Reproduce
Getting this failure after setting up a project with the CLI using the scaffolded routes. Only change to repo is installing Husky and adding the .husky
configs then adding the shopify generated PR for Oxygen deployment. Went to run npm run dev
on node version 20.9.0
and it errors out in the codegen steps.
Expected Behavior
I expected the dev server to start cleanly
Actual Behavior
The dev server process fails on the codegen step. It runs fine when I run the dev server without the --codegen
flag and the codegen command fails when run seperately.
About this issue
- Original URL
- State: closed
- Created 8 months ago
- Comments: 18 (4 by maintainers)
I ran into this isse. Seems wierd, but if the github repo name is different from the project name that was created locally when creating the shopify hydrogen app. You will get that error.
In helping out a friend that cloned down my hydrogen app repo, I had him go in finder and rename his local version of the project to the name of the project I created locally before pushing up to github.
I came to the conclusion of having him rename his local instance of the app to the name of the app I have locally after looking at the codejen.js node module file, which was related to the root directory of the project.
example:
fix:
@EvanMiller12 Have you found the reason why it is like that? Thanks