diff --git a/.husky/pre-commit b/.husky/pre-commit deleted file mode 100755 index 10352a41..00000000 --- a/.husky/pre-commit +++ /dev/null @@ -1,10 +0,0 @@ -#!/usr/bin/env sh - -# This loads nvm.sh and sets the correct PATH before running hook -export NVM_DIR="$HOME/.nvm" -[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" - -. "$(dirname -- "$0")/_/husky.sh" - -npx git-format-staged -f 'prettier --ignore-unknown --stdin --stdin-filepath "{}"' . -npm run typecheck diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 00000000..cc2e65dc --- /dev/null +++ b/.prettierignore @@ -0,0 +1 @@ +public/mockServiceWorker.js diff --git a/package-lock.json b/package-lock.json index 6e244113..92e27078 100644 --- a/package-lock.json +++ b/package-lock.json @@ -46,7 +46,6 @@ "del-cli": "^5.1.0", "eslint": "^8.56.0", "git-format-staged": "^3.1.1", - "husky": "^9.0.11", "msw": "^2.3.1", "npm-run-all": "^4.1.5", "prettier": "^3.3.2", @@ -9032,21 +9031,6 @@ "node": ">= 0.8" } }, - "node_modules/husky": { - "version": "9.0.11", - "resolved": "https://registry.npmjs.org/husky/-/husky-9.0.11.tgz", - "integrity": "sha512-AB6lFlbwwyIqMdHYhwPe+kjOC3Oc5P3nThEoW/AaO2BX3vJDjWPFxYLxokUZOo6RNX20He3AaT8sESs9NJcmEw==", - "dev": true, - "bin": { - "husky": "bin.mjs" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/typicode" - } - }, "node_modules/hyphenate-style-name": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/hyphenate-style-name/-/hyphenate-style-name-1.0.4.tgz", @@ -22738,12 +22722,6 @@ "toidentifier": "1.0.1" } }, - "husky": { - "version": "9.0.11", - "resolved": "https://registry.npmjs.org/husky/-/husky-9.0.11.tgz", - "integrity": "sha512-AB6lFlbwwyIqMdHYhwPe+kjOC3Oc5P3nThEoW/AaO2BX3vJDjWPFxYLxokUZOo6RNX20He3AaT8sESs9NJcmEw==", - "dev": true - }, "hyphenate-style-name": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/hyphenate-style-name/-/hyphenate-style-name-1.0.4.tgz", diff --git a/package.json b/package.json index bb9182da..64cd832e 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "sideEffects": false, "scripts": { "build": "remix build", - "lint": "eslint --ignore-path .gitignore --cache --cache-location ./node_modules/.cache/eslint .", + "lint": "prettier --check . && eslint --ignore-path .gitignore --cache --cache-location ./node_modules/.cache/eslint .", "dev": "remix dev --manual -c \"npm start\"", "start": "wrangler dev ./build/index.js", "prebuild": "npm run clean", @@ -13,10 +13,9 @@ "ci-test": "CI=true run-p typecheck test", "remove-sourcemaps": "del public/build/**/*.map", "deploy": "npm run ci-test && npm run build -- --sourcemap && npm run remove-sourcemaps && wrangler publish --define __RELEASE__:\\\"$(git rev-parse --short HEAD)\\\" --define __SENTRY_DSN__:\\\"$SENTRY_DSN\\\"", - "prettier": "prettier -w --ignore-path .gitignore .", + "prettier": "prettier -w .", "typecheck": "tsc --noEmit --skipLibCheck", "typecheck:watch": "npm run typecheck -- --watch", - "prepare": "husky install", "test": "vitest", "test:ci": "vitest --watch false", "check": "npm run lint && npm run typecheck && npm run test:ci" @@ -62,7 +61,6 @@ "del-cli": "^5.1.0", "eslint": "^8.56.0", "git-format-staged": "^3.1.1", - "husky": "^9.0.11", "msw": "^2.3.1", "npm-run-all": "^4.1.5", "prettier": "^3.3.2", diff --git a/tsconfig.json b/tsconfig.json index bd483896..9a22189c 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,5 +1,5 @@ { - "include": ["remix.env.d.ts", "**/*.ts", "**/*.tsx"], + "include": ["remix.env.d.ts", "**/*.ts", "**/*.tsx", "vitest.config.mts"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2019"], "types": ["@cloudflare/workers-types"], diff --git a/vitest.config.ts b/vitest.config.mts similarity index 100% rename from vitest.config.ts rename to vitest.config.mts