babel-plugin-react-native-web
Advanced tools
Comparing version 0.14.13 to 0.15.0
@@ -6,8 +6,8 @@ { | ||
"name": "babel-plugin-react-native-web", | ||
"version": "0.14.13", | ||
"version": "0.15.0", | ||
"description": "Babel plugin for React Native for Web", | ||
"main": "index.js", | ||
"devDependencies": { | ||
"babel-core": "^6.26.3", | ||
"babel-plugin-tester": "^7.0.4" | ||
"@babel/core": "^7.12.13", | ||
"babel-plugin-tester": "^10.0.0" | ||
}, | ||
@@ -14,0 +14,0 @@ "author": "Nicolas Gallagher", |
const plugin = require('..'); | ||
const pluginTester = require('babel-plugin-tester'); | ||
const pluginTester = require('babel-plugin-tester').default; | ||
@@ -75,3 +75,4 @@ const tests = [ | ||
plugin, | ||
pluginName: 'Rewrite react-native to react-native-web', | ||
tests | ||
}); |
const moduleMap = require('./moduleMap'); | ||
const isCommonJS = opts => opts.commonjs === true; | ||
const isCommonJS = (opts) => opts.commonjs === true; | ||
@@ -36,3 +36,3 @@ const getDistLocation = (importName, opts) => { | ||
module.exports = function({ types: t }) { | ||
module.exports = function ({ types: t }) { | ||
return { | ||
@@ -45,3 +45,3 @@ name: 'Rewrite react-native to react-native-web', | ||
const imports = specifiers | ||
.map(specifier => { | ||
.map((specifier) => { | ||
if (t.isImportSpecifier(specifier)) { | ||
@@ -72,3 +72,3 @@ const importName = specifier.imported.name; | ||
const exports = specifiers | ||
.map(specifier => { | ||
.map((specifier) => { | ||
if (t.isExportSpecifier(specifier)) { | ||
@@ -103,3 +103,3 @@ const exportName = specifier.exported.name; | ||
const imports = id.properties | ||
.map(identifier => { | ||
.map((identifier) => { | ||
const distLocation = getDistLocation(identifier.key.name, state.opts); | ||
@@ -106,0 +106,0 @@ if (distLocation) { |
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
15902
270