babel-plugin-import
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -34,3 +34,3 @@ 'use strict'; | ||
var transformedMethodName = this.camel2DashComponentName ? camel2Dash(methodName) : methodName; | ||
var path = (0, _path.join)(this.libraryName, libraryDirectory, transformedMethodName); | ||
var path = winPath((0, _path.join)(this.libraryName, libraryDirectory, transformedMethodName)); | ||
this.selectedMethods[methodName] = file.addImport(path, 'default'); | ||
@@ -230,2 +230,6 @@ if (style === true) { | ||
} | ||
function winPath(path) { | ||
return path.replace(/\\/g, '/'); | ||
} | ||
module.exports = exports['default']; |
{ | ||
"name": "babel-plugin-import", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Component modular import plugin for babel.", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -97,4 +97,4 @@ # babel-plugin-import | ||
- `["antd", [{ "libraryName": "antd" }]]`: import js modularly | ||
- `["antd", [{ "libraryName": "antd", "style": true }]]`: import js and css modularly (less source files) | ||
- `["antd", [{ "libraryName": "antd", "style": "css" }]]`: import js and css modularly (css built files) | ||
- `["import", [{ "libraryName": "antd" }]]`: import js modularly | ||
- `["import", [{ "libraryName": "antd", "style": true }]]`: import js and css modularly (less source files) | ||
- `["import", [{ "libraryName": "antd", "style": "css" }]]`: import js and css modularly (css built files) |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
14969
296
0