一覧へ戻る
deg-skeletor/skeletor-plugin-rollup(新しいタブで開きます)
主要言語: JavaScript
A skeletor plugin that uses rollup to bundle modules
- star 数
- 0
- watcher 数
- 2
- fork 数
- 0
- issue 数
- 11
- 最終更新
- 2023/01/06
主要言語: JavaScript
A skeletor plugin that uses rollup to bundle modules
The purpose of this plugin is to bundle modules together using Rollup. This plugin is part of the Skeletor ecosystem. To learn more about Skeletor, go here.
Install this plugin into your Skeletor-equipped project via the following terminal command:
npm install --save-dev @deg-skeletor/plugin-rollup
The configuration for this plugin mimics the standard configuration patterns for Rollup (learn more here).
{
input: "source/js/main.js",
output: [
{
file: "dist/js/main-bundle.js",
format: "es"
},
{
file: "dist/js/main-bundle-nomodule.js",
format: "system"
}
],
plugins: [
require('rollup-plugin-babel')({
exclude: 'node_modules/**'
}),
require('rollup-plugin-node-resolve')({
browser: true
}),
require('rollup-plugin-commonjs')()
]
}
[
{
input: "source/js/entryA.js",
output: [{
file: "dist/js/entryA-bundle.js",
format: "es"
}]
},
{
input: "source/js/entryB.js",
output: [{
file: "dist/js/entryB-bundle.js",
format: "es"
}]
}
]
{
input: ["source/js/entryA.js", "source/js/entryB.js"],
output: [
{
dir: "dist/js",
format: "es"
},
{
dir: "dist/js/nomodule",
format: "system"
}
}]
}
For a detailed list of configuration options, check out Rollup's big list of options.