2021-01-18 18:40:19 +01:00
|
|
|
import commonjs from "rollup-plugin-commonjs"
|
|
|
|
import globals from "rollup-plugin-node-globals"
|
|
|
|
import builtins from "rollup-plugin-node-builtins"
|
2021-01-21 17:44:03 +01:00
|
|
|
import polyfills from "rollup-plugin-node-polyfills"
|
|
|
|
import resolve from "rollup-plugin-node-resolve"
|
|
|
|
import json from "@rollup/plugin-json"
|
2021-01-18 18:40:19 +01:00
|
|
|
|
|
|
|
export default {
|
|
|
|
input: "src/index.js",
|
|
|
|
output: {
|
2021-01-19 16:29:49 +01:00
|
|
|
file: "dist/bundle.js",
|
2021-01-18 18:40:19 +01:00
|
|
|
format: "umd",
|
|
|
|
name: "string-templates",
|
2021-01-19 16:29:49 +01:00
|
|
|
exports: "named",
|
|
|
|
globals: {
|
2021-01-21 12:32:26 +01:00
|
|
|
fs: "fs",
|
2021-01-19 16:29:49 +01:00
|
|
|
},
|
2021-01-18 18:40:19 +01:00
|
|
|
},
|
2021-01-21 17:44:03 +01:00
|
|
|
treeshake: true,
|
2021-01-18 18:40:19 +01:00
|
|
|
external: ["fs"],
|
|
|
|
plugins: [
|
2021-01-21 17:44:03 +01:00
|
|
|
polyfills(),
|
|
|
|
resolve({
|
|
|
|
preferBuiltins: false
|
|
|
|
}),
|
2021-01-18 18:40:19 +01:00
|
|
|
commonjs(),
|
|
|
|
globals(),
|
|
|
|
builtins(),
|
2021-01-21 17:44:03 +01:00
|
|
|
json(),
|
2021-01-18 18:40:19 +01:00
|
|
|
],
|
|
|
|
}
|