-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Verbose flag not working in Node API #637
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
Comments
That’s because any output is disabled by default in the API, I’ve updated the API docs to clarify that. |
Ah, thank you for clarifying that. I have just updated my config to add in the
and the output I get from the node api:
I now get the Loading components text and I can see the components that have been found but I cannot tell why the webpage gives me just a white screen because the webpack error has been swallowed somewhere. |
Looks like the CLI does more error handling: react-styleguidist/bin/styleguidist.js Lines 122 to 131 in bc6e651
|
Yep, I have updated my example repo with code duplicated from the bin/styleguidist.js and it is now working as expected displaying the output in the console. Thanks for your help @sapegin. |
* master: Refactor: Replace Markdown links with the Link component instead of the styles (#650) Docs: Clarify logging in Node API (#637) Docs: Correct the `static` modifier note (#643) Docs: Explain behavior for code blocks w/o language tag (#642) Docs: Fix invalid prop type warning (#639) Fix: Clear console on example reload (#638) Docs: Add credits for logo designers (#636) Fix: Update react-docgen (#635) Fix: Correctly print non-Styleguidist exception messages Fix: Fix validation error for uglifyjs-webpack-plugin Docs: Remove react-modal dependency, tweak examples Docs: Update react-styleguidist in CRA example (#632) # Conflicts: # examples/basic/package-lock.json # examples/basic/package.json # examples/cra/package-lock.json # examples/customised/package-lock.json # examples/customised/package.json # examples/express/package-lock.json # examples/express/package.json # examples/sections/package-lock.json # examples/sections/package.json # examples/webpack/package-lock.json # examples/webpack/package.json # package-lock.json # package.json
When running the styleguidist server via the node API, no output is displayed at all regardless of the value of the verbose flag in the configuration file.
An example repo of this in action is available here: https://github.com/EdwardSalter/example
Run running the server via the node API, I would expect the output to still be displayed. This is a bit of a problem since any output from webpack is swallowed so a broken build is impossible to fix.
I unfortunately cannot run the styleguidist server via the CLI since I need to set various variables and mocks in my code before starting the server.
The text was updated successfully, but these errors were encountered: