babel-plugin-import-demo

0.0.1-beta.0 • Public • Published

babel-plugin-import-demo

Example

{ "libraryName": "antd", style: true }

import { Button } from 'antd';
ReactDOM.render(<Button>xxxx</Button>);

           

var _button = require('antd/lib/button');
require('antd/lib/button/style');
ReactDOM.render(<_button>xxxx</_button>);

options

options can be object.

{
  "libraryName": "antd",
  "libraryDirectory": "lib",
  "style": true,
}

style

["import", { "libraryName": "antd", "style": true }]

import js and css modularly (LESS/Sass source files)

/babel-plugin-import-demo/

    Package Sidebar

    Install

    npm i babel-plugin-import-demo

    Weekly Downloads

    2

    Version

    0.0.1-beta.0

    License

    MIT

    Unpacked Size

    13.4 kB

    Total Files

    7

    Last publish

    Collaborators

    • axuebin