feat: support react-docgen-typescript #223
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The previous implementation of #58 is wrong, it ports the Vite version
react-docgen
whilereact-docgen
is implemented by using react-docgen-loader here.Since Rspack doesn't support essential custom template now, we implement this in Vite builder flavor with Rsbuild's flexible API. Which ported https://github.com/joshwooding/vite-plugin-react-docgen-typescript, thanks for @joshwooding's awesome work.
The current implementations of the docgen and builders are shown in the matrix below:
There's one thing I don't understand, in storybookjs/storybook#19399, why
react-docgen
is also always enabled even when usingreact-docgen-typescript
. I tried to disablereact-docgen
,react-docgen-typescript
works fine alone anyway.Friendly ping @joshwooding, thank you for your awesome work of the vite-plugin-react-docgen-typescript and integrations of Vite builder. Could you please explain why react-docgen is always enabled here? Thank you very much!