2022-10-31 03:32:39 +00:00
|
|
|
import commonjs from "@rollup/plugin-commonjs";
|
|
|
|
import json from "@rollup/plugin-json";
|
2023-02-28 03:55:17 +00:00
|
|
|
import { nodeResolve } from "@rollup/plugin-node-resolve";
|
2024-04-09 10:43:28 +00:00
|
|
|
import replace from "@rollup/plugin-replace";
|
2023-03-02 04:24:08 +00:00
|
|
|
import { extractExports } from "@waku/build-utils";
|
2023-02-28 03:55:17 +00:00
|
|
|
|
|
|
|
import * as packageJson from "./package.json" assert { type: "json" };
|
|
|
|
|
|
|
|
const input = extractExports(packageJson);
|
2022-10-31 03:32:39 +00:00
|
|
|
|
|
|
|
export default {
|
2023-02-28 03:55:17 +00:00
|
|
|
input,
|
2022-10-31 03:32:39 +00:00
|
|
|
output: {
|
|
|
|
dir: "bundle",
|
2023-08-16 14:48:13 +00:00
|
|
|
format: "esm"
|
2022-10-31 03:32:39 +00:00
|
|
|
},
|
|
|
|
plugins: [
|
|
|
|
commonjs(),
|
|
|
|
json(),
|
|
|
|
nodeResolve({
|
|
|
|
browser: true,
|
2023-08-16 14:48:13 +00:00
|
|
|
preferBuiltins: false
|
2024-04-09 10:43:28 +00:00
|
|
|
}),
|
|
|
|
replace({
|
|
|
|
"process?.env?.NODE_ENV": JSON.stringify("production")
|
2023-08-16 14:48:13 +00:00
|
|
|
})
|
|
|
|
]
|
2022-10-31 03:32:39 +00:00
|
|
|
};
|