babel-plugin-atom-demand
v0.1.1
Published
babel plugin for import atom on demand
Downloads
3
Readme
babel-plugin-atom-demand
babel plugin for import vue-atom-ui on demand
Install
Example
Converts
import Atom from 'vue-atom-ui';
import { Button } from 'vue-atom-ui';
(roughly) to
var _atom = require('vue-atom-ui/lib/Atom');
var _atom2 = _interopRequireDefault(_atom);
var _button = require('vue-atom-ui/lib/Button');
var _button2 = _interopRequireDefault(_button);
require('vue-atom-ui/lib/css/button.css');
Usage
npm install babel-plugin-atom-demand --save-dev
Via .babelrc
or babel-loader.
{
"plugins": ["atom-demand"]
}
Note
babel-plugin-atom-demand will be not working if you add the vue-atom-ui in webpack config vender