diff --git a/package.json b/package.json index 25fd2d5..b351ad2 100644 --- a/package.json +++ b/package.json @@ -39,8 +39,10 @@ "typescript": "^5.0.2" }, "scripts": { - "build": "tsc --build --clean && tsc --build", - "test": "node --test", + "clean-check": "npm run --build --clean", + "prepublishOnly": "npm run clean-check && tsc --build", + "postpublish": "npm run clean-check", + "test": "npm run clean-check && node --test", "format-code": "prettier --write \"*.js\" \"(test|lib)/*.js\"", "format-code-staged": "pretty-quick --staged --pattern \"*.js\" --pattern \"(test|lib)/*.js\"", "coverage": "c8 --reporter=lcov npm run test"