Skip to content

Commit

Permalink
support esm #25
Browse files Browse the repository at this point in the history
  • Loading branch information
swyxio committed Feb 5, 2022
1 parent 837530a commit 52d9866
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
1 change: 0 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 5 additions & 2 deletions package.json
@@ -1,11 +1,14 @@
{
"name": "svelte-actions",
"version": "0.2.0",
"module": "dist/index.mjs",
"module": "dist/esm/index.mjs",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"scripts": {
"build": "tsc",
"build": "tsc && npm run build:esm && npm run rename:esm",
"build:esm": "tsc --module es2015 --target es5 --outdir dist/esm",
"rename:esm": "find ./dist/esm -name \"*.js\" -exec bash -c 'mv \"$1\" \"${1%.js}\".mjs' - '{}' \\;",
"copy:esm": "mv ./dist/esm/*.mjs ./dist/",
"preversion": "npm run build",
"version": "auto-changelog -p --template keepachangelog && git add CHANGELOG.md",
"prepublishOnly": "git push && git push --tags && gh-release",
Expand Down

0 comments on commit 52d9866

Please sign in to comment.