-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Storybook doesn't run in dev mode with hot reload like start-storybook
#8484
Comments
I was able to change he executor to use
But ideally, this is something that is built into one of the generators. Maybe it's necessary to start building @nrwl/storybook/ generators? Either way, having hot module reloading from intial setup is ideal |
Hi there! So, hot reload works for you when you switch the executor? |
I am seeing the same behavior. I staying up to date with the @next releases of storybook (currently 6.5.0.alpha.15). I have storybook working, but it doesn't hot reload, or even update with a manual reload, I have to kill and restart storybook to get any changes. |
@coltpini Oh I see! Don't worry, I can help you out. Can you share a repository reproducing your issue? I can show you which parts you need to tweak, especially for the watch mode/hot reload. But let me ask you something. Does your workspace have an |
@sir-captainmorgan21 I would suggest this solution. Please let me know if it works. |
Oh, also, what if you pass |
@mandarini from what I can tell the function you are calling no longer supports "watch" as a config. You may want to use the CLIConfig interface in storybook/core or common (can't remember which one) if their package surfaces it. I dug into the nx src code a bit to see what could be missing, and that where I realized that 'watch' was removed. I tried digging into storybook's code to understand exactly what function But yes. Changing the executor did the trick for me. I am on 6.5.0-alpha.13. Im guessing I should probably not jump to 14 haha. But yea @coltpini until they get a baked-in solution, you can go with updating the executor for now. |
@mandarini hey. Saw you go assigned to this today. Was wondering if you were looking to knock it out this week? Im writing up some docs on initiating our package libs, and wanted to know if I could omit including my workaround in the docs or if a fix would be out soon. Thanks! |
Hi @sir-captainmorgan21 ! I am not sure when this will be ready, it should be soon, but I don't want to make false promises. So go ahead and document your workaround, and once we put a fix in a next version of Nx I'll make sure to post it here! :) |
Hey @sir-captainmorgan21 ! ExplanationStorybook's It merges in the following order
We were passing Storybook providing the |
Just tested it locally, and it works great! :) Thanks @Coly010 ! |
@mandarini @Coly010 awesome thanks! |
@Coly010 what version will this be? |
@sir-captainmorgan21 Not entirely sure. It'll likely land in the next release. I'll update this thread when it does |
@sir-captainmorgan21 This has been released as part of Nx v 13.7.2! :) |
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context. |
Current Behavior
I have storybook set up with NX and Angular. Everything is working fine except I am forced to run
nx run storybook:<my-project>
after every change I make.start-storybook
runs this as a dev server with hot module reloading. Am I missing a cli option to get this, or is nx using the wrong builder?Expected Behavior
I would expect serving storybook to have hot reloading available.
Steps to Reproduce
Set up an NX project with storybook configuration and run the
nx run storybook:<project>
command.Environment
The text was updated successfully, but these errors were encountered: