babel-preset-rax
Advanced tools
Comparing version 0.6.4 to 0.6.5
@@ -1,40 +0,30 @@ | ||
'use strict'; | ||
"use strict"; | ||
var _resolvePlugins = require('./resolvePlugins'); | ||
var _resolvePlugins = _interopRequireDefault(require("./resolvePlugins")); | ||
var _resolvePlugins2 = _interopRequireDefault(_resolvePlugins); | ||
var _babelPresetFlow = _interopRequireDefault(require("babel-preset-flow")); | ||
var _babelPresetFlow = require('babel-preset-flow'); | ||
var _babelPresetEs = _interopRequireDefault(require("babel-preset-es2016")); | ||
var _babelPresetFlow2 = _interopRequireDefault(_babelPresetFlow); | ||
var _babelPresetEs2 = _interopRequireDefault(require("babel-preset-es2017")); | ||
var _babelPresetEs = require('babel-preset-es2016'); | ||
var _babelPresetStage = _interopRequireDefault(require("babel-preset-stage-0")); | ||
var _babelPresetEs2 = _interopRequireDefault(_babelPresetEs); | ||
var _babelPresetEs3 = require('babel-preset-es2017'); | ||
var _babelPresetEs4 = _interopRequireDefault(_babelPresetEs3); | ||
var _babelPresetStage = require('babel-preset-stage-0'); | ||
var _babelPresetStage2 = _interopRequireDefault(_babelPresetStage); | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
module.exports = { | ||
presets: [_babelPresetFlow2.default, _babelPresetEs2.default, _babelPresetEs4.default, _babelPresetStage2.default], | ||
plugins: (0, _resolvePlugins2.default)(['syntax-jsx', 'transform-react-display-name', ['transform-react-jsx', { | ||
presets: [_babelPresetFlow.default, _babelPresetEs.default, _babelPresetEs2.default, _babelPresetStage.default], | ||
plugins: (0, _resolvePlugins.default)(['transform-decorators-legacy', 'syntax-jsx', 'transform-react-display-name', ['transform-react-jsx', { | ||
pragma: 'createElement' // default pragma is React.createElement | ||
}], 'transform-jsx-stylesheet', | ||
// webpack 3 may not need this plugin | ||
}], 'transform-jsx-stylesheet', // webpack 3 may not need this plugin | ||
process.env.BABEL_ADD_MODULE_EXPORTS !== 'false' ? 'add-module-exports' : null]), | ||
env: { | ||
development: { | ||
plugins: (0, _resolvePlugins2.default)(['transform-react-jsx-source', 'transform-react-jsx-self']) | ||
plugins: (0, _resolvePlugins.default)(['transform-react-jsx-source', 'transform-react-jsx-self']) | ||
}, | ||
production: { | ||
plugins: (0, _resolvePlugins2.default)(['transform-react-constant-elements', 'minify-dead-code-elimination']) | ||
plugins: (0, _resolvePlugins.default)(['transform-react-constant-elements', 'minify-dead-code-elimination']) | ||
} | ||
} | ||
}; |
@@ -1,2 +0,2 @@ | ||
'use strict'; | ||
"use strict"; | ||
@@ -7,2 +7,3 @@ Object.defineProperty(exports, "__esModule", { | ||
exports.default = resolvePlugins; | ||
function resolvePlugins(plugins) { | ||
@@ -13,4 +14,5 @@ return plugins.map(function (plugin) { | ||
plugin = [plugin]; | ||
} | ||
// Only resolve the plugin if it's a string reference. | ||
} // Only resolve the plugin if it's a string reference. | ||
if (typeof plugin[0] === 'string') { | ||
@@ -20,5 +22,7 @@ plugin[0] = require('babel-plugin-' + plugin[0]); | ||
} | ||
return plugin; | ||
}); | ||
} | ||
module.exports = exports['default']; | ||
module.exports = exports["default"]; |
{ | ||
"name": "babel-preset-rax", | ||
"version": "0.6.4", | ||
"version": "0.6.5", | ||
"description": "Babel preset for all Rax plugins.", | ||
@@ -22,3 +22,4 @@ "license": "BSD-3-Clause", | ||
"babel-plugin-syntax-jsx": "^6.18.0", | ||
"babel-plugin-transform-jsx-stylesheet": "^0.6.4", | ||
"babel-plugin-transform-decorators-legacy": "^1.3.5", | ||
"babel-plugin-transform-jsx-stylesheet": "^0.6.5", | ||
"babel-plugin-transform-react-constant-elements": "^6.23.0", | ||
@@ -25,0 +26,0 @@ "babel-plugin-transform-react-display-name": "^6.23.0", |
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
3800
14
39