*Update dist

This commit is contained in:
Derrick Hammer 2023-01-01 12:40:32 -05:00
parent 7776703d3f
commit a008816085
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
2 changed files with 10 additions and 6 deletions

3
dist/index.d.ts vendored
View File

@ -1,2 +1,3 @@
import { RollupOptions } from "rollup";
export default function preset(): RollupOptions;
import { RollupNodeResolveOptions } from "@rollup/plugin-node-resolve";
export default function preset(globalOptions: RollupOptions, resolveOptions?: RollupNodeResolveOptions, commonJsOptions?: any): RollupOptions;

13
dist/index.js vendored
View File

@ -1,11 +1,13 @@
import { defineConfig } from "rollup";
import commonjs from "@rollup/plugin-commonjs";
import { nodeResolve } from "@rollup/plugin-node-resolve";
import { nodeResolve, } from "@rollup/plugin-node-resolve";
import { bundleNativeModulesPlugin } from "@lumeweb/rollup-plugin-bundle-native-modules";
import typescript from "@rollup/plugin-typescript";
import json from "@rollup/plugin-json";
export default function preset() {
return defineConfig({
// @ts-ignore
import merger from "object-merger";
export default function preset(globalOptions, resolveOptions = {}, commonJsOptions = {}) {
return merger(globalOptions, defineConfig({
plugins: [
typescript(),
json(),
@ -13,8 +15,9 @@ export default function preset() {
nodeResolve({
mainFields: ["main"],
exportConditions: ["node", "require", "default"],
...resolveOptions,
}),
commonjs(),
commonjs(commonJsOptions),
],
});
}));
}