This repository has been archived on 2024-07-22. You can view files and clone it, but cannot push or open issues or pull requests.
Doric/doric-cli/assets-lib/rollup.config.js
2022-07-13 19:17:51 +08:00

22 lines
565 B
JavaScript

import resolve from "@rollup/plugin-node-resolve";
import commonjs from "@rollup/plugin-commonjs";
import json from "@rollup/plugin-json";
export default [
{
input: `.dxx/index.js`,
output: {
format: "cjs",
file: `dist/bundle___$__.js`,
sourcemap: true,
},
plugins: [resolve({ mainFields: ["jsnext"] }), commonjs(), json()],
external: ["reflect-metadata", "doric"],
onwarn: function (warning) {
if (warning.code === "THIS_IS_UNDEFINED") {
return;
}
console.warn(warning.message);
},
},
];