Skip to content

Commit

Permalink
fix: fix helper rollup config
Browse files Browse the repository at this point in the history
  • Loading branch information
daybrush committed Jun 20, 2023
1 parent 5e7f9c4 commit c8ee6a7
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 6 deletions.
17 changes: 14 additions & 3 deletions packages/helper/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ module.exports = builder([
},
{
...defaultOptions,
input: "src/index.umd.ts",
input: "src/index.cjs.ts",
output: "./dist/helper.cjs.js",
format: "cjs",
exports: "named",
Expand All @@ -25,7 +25,18 @@ module.exports = builder([
input: "src/index.umd.ts",
output: "./dist/helper.js",
format: "umd",
exports: "named",
name: "helper",
exports: "default",
resolve: true,
name: "MoveableHelper",
},
{
...defaultOptions,
input: "src/index.umd.ts",
output: "./dist/helper.min.js",
format: "umd",
exports: "default",
resolve: true,
uglify: true,
name: "MoveableHelper",
},
]);
6 changes: 6 additions & 0 deletions packages/helper/src/index.cjs.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import * as modules from "./index";


module.exports = modules;
export * from "./index";
export default modules;
3 changes: 0 additions & 3 deletions packages/helper/src/index.umd.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
import * as modules from "./index";


module.exports = modules;
export * from "./index";
export default modules;

0 comments on commit c8ee6a7

Please sign in to comment.