Skip to content

Commit

Permalink
Chore: cleanup exports, rollup config
Browse files Browse the repository at this point in the history
  • Loading branch information
bigtimebuddy committed Aug 5, 2022
1 parent 425290b commit 22a79d9
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 16 deletions.
12 changes: 6 additions & 6 deletions config/rollup.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ const banner = `/*!
*/
export default [
{
input: "src/index.ts",
input: pkg.source,
external,
plugins,
output: [
Expand All @@ -52,28 +52,28 @@ export default [
freeze: false,
sourcemap,
format: "cjs",
file: "dist/pixi-gif.cjs.js",
file: pkg.main,
},
{
banner,
freeze: false,
sourcemap,
format: "esm",
file: "dist/pixi-gif.esm.js",
file: pkg.module,
},
],
},
{
input: "src/index.ts",
input: pkg.source,
external,
plugins,
output: {
banner,
freeze: false,
format: "iife",
name: "PIXI.gif",
name: pkg.namespace,
sourcemap,
file: "dist/pixi-gif.js",
file: pkg.bundle,
globals: {
"@pixi/loaders": "PIXI",
"@pixi/core": "PIXI",
Expand Down
19 changes: 9 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,17 @@
"name": "@pixi/gif",
"version": "1.1.1",
"description": "Animated GIF Runtime for PixiJS",
"source": "./src/index.ts",
"main": "./dist/pixi-gif.cjs.js",
"module": "./dist/pixi-gif.esm.js",
"module": "./dist/pixi-gif.esm.mjs",
"bundle": "./dist/pixi-gif.js",
"types": "./index.d.ts",
"namespace": "PIXI.gif",
"exports": {
".": {
"import": {
"types": "./index.d.ts",
"default": "./dist/pixi-gif.esm.js"
},
"require": {
"types": "./index.d.ts",
"default": "./dist/pixi-gif.cjs.js"
}
"import": "./dist/pixi-gif.esm.mjs",
"require": "./dist/pixi-gif.cjs.js",
"types": "./index.d.ts"
}
},
"scripts": {
Expand Down Expand Up @@ -88,7 +86,8 @@
"engines",
"pre-commit",
"devDependencies",
"eslintConfig"
"eslintConfig",
"source"
]
},
"devDependencies": {
Expand Down

0 comments on commit 22a79d9

Please sign in to comment.