26 lines
633 B
JavaScript
26 lines
633 B
JavaScript
// SPDX-FileCopyrightText: 2021 Johannes Loher
|
|
//
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
const typescript = require("rollup-plugin-typescript2");
|
|
const sourcemaps = require("rollup-plugin-sourcemaps");
|
|
const { terser } = require("rollup-plugin-terser");
|
|
|
|
/**
|
|
* @type {import('rollup').RollupOptions}
|
|
*/
|
|
const config = {
|
|
input: "src/module/ds4.ts",
|
|
output: {
|
|
dir: "dist/module",
|
|
format: "es",
|
|
sourcemap: true,
|
|
},
|
|
plugins: [
|
|
sourcemaps(),
|
|
typescript({}),
|
|
process.env.NODE_ENV === "production" && terser({ ecma: 2020, keep_fnames: true }),
|
|
],
|
|
};
|
|
|
|
module.exports = config;
|