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

Add and implement codegen in hello-world #1039

Closed
wants to merge 10 commits into from

Conversation

juanpprieto
Copy link
Contributor

WHY are these changes introduced?

hello-world template is not defaulting to using codegen

WHAT is this pull request doing?

  • adds codegen flag
  • use generated codegen type on root.tsx

@juanpprieto juanpprieto force-pushed the juanpprieto/hello-world-codegen branch 2 times, most recently from 76c7406 to 91a958b Compare June 26, 2023 08:23
@juanpprieto juanpprieto requested a review from frandiox June 26, 2023 09:29
@juanpprieto
Copy link
Contributor Author

juanpprieto commented Jun 26, 2023

@frandiox any idea why the shopify hydrogen codegen-unstable is failing to find any queries during CI?.

I changed the build command to shopify hydrogen codegen-unstable && shopify hydrogen build to ensure the types get generated before the build and typecheck runs which works ok locally.

There's a suitable query at root.tsx that works ok on local. I'm trying to see if we can avoid tracking storefrontapi.generated.d.ts on the hello-world template

@frandiox
Copy link
Contributor

@juanpprieto I'm adding the --codegen-unstable flag to the build command here, and also ensuring we remove that flag for JS projects from the npm build script.

I've made a change there with query paths that might fix the issue you have on CI. Not sure but you can give it a try.

@michenly
Copy link
Contributor

@juanpprieto I am going to close this PR since we are talking about removing Hello world. Feel free to re-open and re-work the PR if needed.

@michenly michenly closed this Feb 14, 2024
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

Successfully merging this pull request may close these issues.

4 participants