Remove core .metadata properties and resolveModuleSource#6343
Merged
loganfsmyth merged 8 commits intobabel:masterfrom Sep 29, 2017
Merged
Remove core .metadata properties and resolveModuleSource#6343loganfsmyth merged 8 commits intobabel:masterfrom
loganfsmyth merged 8 commits intobabel:masterfrom
Conversation
Collaborator
|
Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/5094/ |
hzoo
reviewed
Sep 29, 2017
| @@ -1,15 +0,0 @@ | |||
| export default class Store { | |||
hzoo
approved these changes
Sep 29, 2017
Member
hzoo
left a comment
There was a problem hiding this comment.
amazing, love the -469 lines, keep it up!!
existentialism
approved these changes
Sep 29, 2017
Member
|
hzoo
reviewed
Sep 29, 2017
| dynamicImportIds: Object; | ||
| dynamicImports: Array<Object>; | ||
| declarations: Object; | ||
| usedHelpers: Object; |
9b3e7b5 to
a390a92
Compare
loganfsmyth
commented
Sep 29, 2017
|
|
||
| resolveModuleSource: { | ||
| version: 6, | ||
| message: "Use `babel-plugin-module-resolver@3`'s 'resolvePath' options", |
jscinoz
added a commit
to AvokaTech/babel-plugin-lodash
that referenced
this pull request
Oct 20, 2017
Babel no longer does this internally as of babel/babel#6343. This commit implements the same traversal as part of this plugin, using the same code that was removed from Babel with some trivial modifications.
jdalton
pushed a commit
to lodash/babel-plugin-lodash
that referenced
this pull request
Oct 20, 2017
* Add dependencies on babel-types and babel-helper-module-imports * Traverse file AST ourselves to build module metadata. Babel no longer does this internally as of babel/babel#6343. This commit implements the same traversal as part of this plugin, using the same code that was removed from Babel with some trivial modifications. * Use addDefault from babel-helper-module-imports to add our imports. file.addImport is deprecated by Babel and attempting to use it will throw.
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
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.
Basically tidying up. Removing:
resolveModuleSourcewhich ran on ES6 imports only (unless my removebabel-helper-module-importsaddition) and kind of useless anyway because it never runs onrequire()calls.usedHelperswhich I can't think of a good usecase for and I don't see a use for.babel.analysesince it does nothing thatbabel.transformdoesn't do.path.mark()because it, as far as I can tell, something that is super easily to implement in your own plugin, and not used anywhere I can think.