snarkjs/config/rollup.iife.config.js

24 lines
606 B
JavaScript
Raw Normal View History

2020-07-11 11:31:52 +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";
export default {
input: "main.js",
output: {
file: "build/snarkjs.js",
format: "iife",
sourcemap: "inline",
globals: {
os: "null"
},
name: "snarkjs"
},
plugins: [
ignore(["fs", "os", "crypto", "readline", "worker_threads"]),
resolve(),
commonJS(),
replace({ "process.browser": !!process.env.BROWSER }),
]
};