metro-babel-transformer
Advanced tools
Comparing version 0.73.7 to 0.74.0
{ | ||
"name": "metro-babel-transformer", | ||
"version": "0.73.7", | ||
"version": "0.74.0", | ||
"description": "🚇 Base Babel transformer for Metro.", | ||
@@ -22,5 +22,5 @@ "main": "src/index.js", | ||
"hermes-parser": "0.8.0", | ||
"metro-source-map": "0.73.7", | ||
"metro-source-map": "0.74.0", | ||
"nullthrows": "^1.1.1" | ||
} | ||
} |
@@ -36,2 +36,7 @@ /** | ||
sourceType: "module", | ||
// NOTE(EvanBacon): We split the parse/transform steps up to accommodate | ||
// Hermes parsing, but this defaults to cloning the AST which increases | ||
// the transformation time by a fair amount. | ||
// You get this behavior by default when using Babel's `transform` method directly. | ||
cloneInputAst: false, | ||
}; | ||
@@ -44,6 +49,9 @@ const sourceAst = options.hermesParser | ||
: parseSync(src, babelConfig); | ||
const { ast } = transformFromAstSync(sourceAst, src, babelConfig); | ||
// Generate the function map before we transform the AST to | ||
// ensure we aren't reading from mutated AST. | ||
const functionMap = generateFunctionMap(sourceAst, { | ||
filename, | ||
}); | ||
const { ast } = transformFromAstSync(sourceAst, src, babelConfig); | ||
return { | ||
@@ -50,0 +58,0 @@ ast: nullthrows(ast), |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5729
64
+ Addedmetro-source-map@0.74.0(transitive)
+ Addedmetro-symbolicate@0.74.0(transitive)
+ Addedob1@0.74.0(transitive)
- Removedmetro-source-map@0.73.7(transitive)
- Removedmetro-symbolicate@0.73.7(transitive)
- Removedob1@0.73.7(transitive)
Updatedmetro-source-map@0.74.0