vite-plugin-importer
Advanced tools
Comparing version 0.2.1 to 0.2.2
{ | ||
"name": "vite-plugin-importer", | ||
"version": "0.2.1", | ||
"version": "0.2.2", | ||
"main": "src/index.js", | ||
@@ -5,0 +5,0 @@ "description": "Integration for babel-plugin-import", |
@@ -31,2 +31,14 @@ # vite-plugin-importer | ||
}), | ||
usePluginImport({ | ||
libraryName: 'vant', | ||
libraryDirectory: 'es', | ||
style: (name) => `${name}/style/less`, | ||
}), | ||
usePluginImport({ | ||
libraryName: 'element-plus', | ||
customStyleName: (name) => { | ||
return `element-plus/lib/theme-chalk/${name}.css`; | ||
}, | ||
}) | ||
// Other configurations welcome PR | ||
]; | ||
@@ -33,0 +45,0 @@ }) |
@@ -16,2 +16,3 @@ const babelImport = require('babel-plugin-import'); | ||
const result = babel.transformSync(code, { | ||
configFile: false, | ||
ast: true, | ||
@@ -18,0 +19,0 @@ plugins, |
3787
35
51