-
Notifications
You must be signed in to change notification settings - Fork 9
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
[Fix] Add codegen to watch command #8747
Conversation
Cannot run on WSL Running in a Linux environment |
Hmm, odd. I am also on WSL and it seemed to work for me 🤔
Which query did you delete? Do you remember? I'd like to see if I can reproduce. UpdateSo, @vd1992 I finally got around to trying to reproduce this based on your feedback but I am having trouble 😢 Still seems to work for me 😕 graphql-watch.mp4 |
I'm not sure what to think here. 😆 Codegen doesn't seem to be watching for changes to the .graphql files. 👎 But I can manually run codegen with having to do the force flag. 👍 On the other hand, the new stuff with the client-preset is working great in watch mode, so maybe we don't care that much about the deprecated codegen stuff? |
Ohh, that is a good point. Ever since we merged the Update: Got it working with the old config in backport codegen watch to deprecated config |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yay! This is working great for me now.
Awesome! This is going to make the |
🤖 Resolves #8401
👋 Introduction
This allows codegen to re-run on changes to our operations. It also prevents codegen from being cached since this seemed to be causing more problems than it was solving.
🕵️ Details
We were only running
codegen
on the start of the watch command but it never actually watched any files. This uses concurrently to have it run in watch mode alongside thetsup
watch.Note
Something that is a tad annoying is that when you kill the process, you need to do it twice. This is a known bug and hopefully gets fixed.
🧪 Testing
Assist reviewers with steps they can take to test that the PR does what it says it does.
npm run watch
apps/web