-
-
Notifications
You must be signed in to change notification settings - Fork 312
feat!: Migrate to babel toolchain #638
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9eed5b7 to
9c84bf9
Compare
267c3cc to
7ce745f
Compare
BREAKING CHANGE: Internally react-docgen now uses babel only. There are tons of breaking changes in this new version. Read the MIGRATE.md Release-As: v6.0.0-alpha.4
BREAKING CHANGE: The return values of `resolveObjectValuesToArray` are now in the order they are defined in the source code.
visitors are now pre-exploded and are cached in the module scope instead of creating them on every call. This change brought the benchmark from 170ops/s to 225ops/sec
BREAKING CHANGE: The main API changed and now includes only 2 arguments. Read MIGRATE.md for more info.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Finally, I finished the migration for version 6 of react-docgen.
There is still a bunch to do though, but the biggest part is done. 🎉
The cli is currently broken and not working, but I want to address this afterwards.
The most significant change besides the babel AST is that the NodePaths are now stateful, which means that the parser, importer, and options can now be directly accessed on every NodePath. This made it unnecessary to pass through the importer in nearly every single function.
And the best part, it looks like it is actually a lot faster, but I have to add more cases to the benchmark to be sure.
Breaking changes:
Ref #502