chore: run build on prepack

This commit is contained in:
Yarmo Mackenbach 2024-11-25 19:42:23 +01:00
parent 9ae9aa8e2c
commit f3863918d6
No known key found for this signature in database
GPG key ID: C248C28D432560ED
3 changed files with 11 additions and 3 deletions

View file

@ -19,6 +19,7 @@ package-lock.json
rollup.config.js rollup.config.js
\.editorconfig \.editorconfig
\.gitignore \.gitignore
\.npmignore
\.licenseignore \.licenseignore
flake.nix flake.nix
flake.lock flake.lock

5
.npmignore Normal file
View file

@ -0,0 +1,5 @@
node_modules
ignore
tests
docs
.env

View file

@ -58,7 +58,8 @@
"rollup-plugin-visualizer": "^5.9.2" "rollup-plugin-visualizer": "^5.9.2"
}, },
"scripts": { "scripts": {
"build": "rm -rf ./dist/ && npm run build:bundle && npm run build:minify", "clean": "rm -rf ./dist/",
"build": "npm run clean && npm run build:bundle && npm run build:minify",
"build:bundle": "rollup -c", "build:bundle": "rollup -c",
"build:minify": "minify ./dist/doip.core.js > ./dist/doip.core.min.js && minify ./dist/doip.fetchers.js > ./dist/doip.fetchers.min.js && minify ./dist/doip.fetchers.minimal.js > ./dist/doip.fetchers.minimal.min.js", "build:minify": "minify ./dist/doip.core.js > ./dist/doip.core.min.js && minify ./dist/doip.fetchers.js > ./dist/doip.fetchers.min.js && minify ./dist/doip.fetchers.minimal.js > ./dist/doip.fetchers.minimal.min.js",
"license:check": "license-check-and-add check", "license:check": "license-check-and-add check",
@ -69,7 +70,8 @@
"lint:fix": "eslint ./src --fix", "lint:fix": "eslint ./src --fix",
"pretest": "node ./prerelease.js && npm run lint && npm run license:check", "pretest": "node ./prerelease.js && npm run lint && npm run license:check",
"test": "mocha", "test": "mocha",
"prepare": "husky install" "prepare": "husky install",
"prepack": "npm run build"
}, },
"repository": { "repository": {
"type": "git", "type": "git",