William Grasel
main | browser | module | es2015 | |
---|---|---|---|---|
ES version | ES5 | ES5 | ES5 | ES2015 |
Module format | CJS | UMD | ESM | ESM |
webpack | ✔ | ✔ | ✔ | – |
Rollup | (✔) | (✔) | ✔ | – |
jspm | ✔ | – | – | – |
{
...
"main": "index.js",
...
}
{
...
"main": "index.js",
"browser": "bundles/index.umd.js",
...
}
{
...
"main": "index.js",
"browser": "bundles/index.umd.js",
"module": "module/index.js",
...
}
{
...
"main": "index.js",
"browser": "bundles/index.umd.js",
"module": "module/index.js",
"es2015": "es2015/index.js",
...
}
$ ng generate library my-lib
$ ng generate library my-lib
$ ng build my-lib
$ ng generate library my-lib
$ ng build my-lib
$ npm publish dist/my-lib
$ npm install -g semantic-release-cli
$ cd your-module
$ semantic-release-cli setup