@gem-mine/script-rollup
TypeScript icon, indicating that this package has built-in type declarations

2.7.14 • Public • Published

script-rollup 组件库模式说明

TreeShaking

要求@script-rollup@2.0.1-alpha.1

  • 要求使用方为webpack2

配置要求

gem-mine.config.js中设置

module.exports = {
  componentLibraryMode: true,
  target: ['esm']
}

依赖声明

dependencies会自动判定为运行时依赖。如果需要打包进代码中,请使用devDependencies

目录结构

请保持如下目录结构

  • src/index.js 引入所有组件,请保持ES6 export写法
  • src/*/index.js为一个组件入口,可以相互引用,可以自由引用样式

package.json

发布时请设置如下内容

"sideEffects": [
  "dist/esm/*/*",
  "*.less"
],
"main": "dist/esm/index.js",

Readme

Keywords

none

Package Sidebar

Install

npm i @gem-mine/script-rollup

Weekly Downloads

64

Version

2.7.14

License

ISC

Unpacked Size

85 kB

Total Files

36

Last publish

Collaborators

  • caolvchong
  • wengzp
  • guoyh
  • mraiguo
  • amazebird
  • githoniel
  • janya
  • gylllll