snarkjs/config/rollup.iife_min.config.js

25 lines
645 B
JavaScript
Raw Normal View History

2020-07-13 08:21:03 +03:00
import resolve from "rollup-plugin-node-resolve";
import commonJS from "rollup-plugin-commonjs";
import ignore from "rollup-plugin-ignore";
import replace from "rollup-plugin-replace";
import { terser } from "rollup-plugin-terser";
export default {
input: "main.js",
output: {
file: "build/snarkjs.min.js",
format: "iife",
globals: {
os: "null"
},
name: "snarkjs"
},
plugins: [
ignore(["fs", "os", "crypto", "readline", "worker_threads"]),
resolve(),
commonJS(),
replace({ "process.browser": !!process.env.BROWSER }),
terser()
]
};