Skip to content

Commit

Permalink
Add new rollup-terser plugin
Browse files Browse the repository at this point in the history
Use @rollup/plugin-terser to minify JS build.
TrySound/rollup-plugin-terser#120 (comment)
  • Loading branch information
nikolas committed Nov 9, 2022
1 parent aaecd21 commit 8230392
Show file tree
Hide file tree
Showing 3 changed files with 125 additions and 1 deletion.
121 changes: 121 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"@babel/register": "^7.18.9",
"@rollup/plugin-commonjs": "^23.0.0",
"@rollup/plugin-node-resolve": "^15.0.0",
"@rollup/plugin-terser": "^0.1.0",
"eslint": "^8.25.0",
"eslint-plugin-svelte": "^2.8.0",
"mocha": "^10.0.0",
Expand Down
4 changes: 3 additions & 1 deletion rollup.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import svelte from "rollup-plugin-svelte";
import commonjs from "@rollup/plugin-commonjs";
import resolve from "@rollup/plugin-node-resolve";
import css from "rollup-plugin-css-only";
import terser from '@rollup/plugin-terser';

import pkg from "svelte-preprocess";
const { replace } = pkg;
Expand Down Expand Up @@ -54,7 +55,8 @@ export default {
browser: true,
dedupe: ["svelte"],
}),
commonjs()
commonjs(),
terser()
],
watch: {
clearScreen: false,
Expand Down

0 comments on commit 8230392

Please sign in to comment.