xhl_libv2

1.0.11 • Public • Published

node 16.9.1 npm i rollup -g # 全局安装

使用方式 eg

<script> // main.js 全量使用 import xhl_lib from 'xhl_lib'; app.use(xhl_lib); </script>

组件内手动按需引用

<script> import hello from 'xhl_libv2/xhl-ui/components/test/index.js'; export default { components:{hello}, }; </script>

安装bable插件 npm install babel-plugin-component --save-dev

<script> module.exports = { "plugins": [ [ "component", { "libraryName": "xhl_libv2", "style": false, // or 'css' "libDir": 'xhl-ui/components' }, 'xhl_libv2' ] ] } // 使用 import {test} from 'xhl_lib' </script>

npm 修改以及发布

修改完代码之后 npm login 版本号修改一下 不能和已有的重复 npm publish

Readme

Keywords

none

Package Sidebar

Install

npm i xhl_libv2

Weekly Downloads

1

Version

1.0.11

License

ISC

Unpacked Size

74.9 kB

Total Files

13

Last publish

Collaborators

  • zhaojiankun