diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..0ef8e44 --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +side-effects-cache = false diff --git a/lefthook.yml b/lefthook.yml new file mode 100644 index 0000000..1596122 --- /dev/null +++ b/lefthook.yml @@ -0,0 +1,6 @@ +pre-commit: + commands: + check: + glob: "*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}" + run: pnpm biome check --write --no-errors-on-unmatched --files-ignore-unknown=true --colors=off {staged_files} + stage_fixed: true diff --git a/package.json b/package.json index 207f149..eb2be41 100644 --- a/package.json +++ b/package.json @@ -55,6 +55,7 @@ "@types/ws": "^8.5.13", "autoprefixer": "^10.4.20", "babel-plugin-react-compiler": "19.0.0-beta-55955c9-20241229", + "lefthook": "^1.10.9", "postcss": "^8.4.49", "react-router-dom": "^7.1.1", "tailwindcss": "^3.4.17", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 5934e98..c5de2bc 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -143,6 +143,9 @@ importers: babel-plugin-react-compiler: specifier: 19.0.0-beta-55955c9-20241229 version: 19.0.0-beta-55955c9-20241229 + lefthook: + specifier: ^1.10.9 + version: 1.10.9 postcss: specifier: ^8.4.49 version: 8.4.49 @@ -2123,6 +2126,60 @@ packages: resolution: {integrity: sha512-P2bSOMAc/ciLz6DzgjVlGJP9+BrJWu5UDGK70C2iweC5QBIeFf0ZXRvGjEj2uYgrY2MkAAhsSWHDWlFtEroZWw==} engines: {node: '>=0.6.0'} + lefthook-darwin-arm64@1.10.9: + resolution: {integrity: sha512-2ceuIUkwTcTncaYH/Y2bw2m3kuNkd+vqaJXQuSh0DAa0TRS9HmEQEV0CtLUlTp5tLg6PPHdTHnu2AhKAjfHhyw==} + cpu: [arm64] + os: [darwin] + + lefthook-darwin-x64@1.10.9: + resolution: {integrity: sha512-eAUbFtEj5TtYsm533uvQQSJTc8SLhgGRyRCUa+hmFtKQROaiw2buqc5ZOTBuegC8iAl7cHT1ydN2oakE+FLfVg==} + cpu: [x64] + os: [darwin] + + lefthook-freebsd-arm64@1.10.9: + resolution: {integrity: sha512-A6ZFPg/9eXgs75SojFeZfMMfMgqB0fgVdtOl0mxrQXXqxTxFWD5wCGPPJIc/Pbzaaz66ZOYZt/36+MyMdgjWJQ==} + cpu: [arm64] + os: [freebsd] + + lefthook-freebsd-x64@1.10.9: + resolution: {integrity: sha512-PF3Jjm9JHFnY41yM9wljK0y8xE/sx/sRNtNZWJzlOqC5YFUrNNBejPz5kU40mpBWd8yOclXxqBOeeZqDH64+dQ==} + cpu: [x64] + os: [freebsd] + + lefthook-linux-arm64@1.10.9: + resolution: {integrity: sha512-Es4y3cxUtSBAF9nPkDXWC7+/tScPeRu3GVeeupv3+iMZkVACfM1DCIrK4iG9Syh7y2TLWAj6ThFArqeiRjFeog==} + cpu: [arm64] + os: [linux] + + lefthook-linux-x64@1.10.9: + resolution: {integrity: sha512-OSlcltu2MRrLY1bWwqm4MvNOvTskUonmzTR8Bu7dy8O+80YPjPSnowLeYzfxXd8RI1w2nkwL3XKVuoDiJ3nVUw==} + cpu: [x64] + os: [linux] + + lefthook-openbsd-arm64@1.10.9: + resolution: {integrity: sha512-wmdWGRmTK8ii4KAvAj5AhTK0EWh65vdcBt1ndsd7qXG08cStevCpsZ/cOLDVWBjjaqYkVpVsYkJNf5dwuXp21w==} + cpu: [arm64] + os: [openbsd] + + lefthook-openbsd-x64@1.10.9: + resolution: {integrity: sha512-LLkPdy2+TIdCOGReqsODo46SmQpBjPB00gRftA1doA6ZaPzqk87moGrOmlsaLx1SkYKxctBYZc9j9MxCo2GVCg==} + cpu: [x64] + os: [openbsd] + + lefthook-windows-arm64@1.10.9: + resolution: {integrity: sha512-Q9e3pbDjQyguXW810M1lerpcpKkeDYOTuISn86IIiKxPAawDY7JqUGWcyFsmoED/S3RJBrUp53VM3xg/dkrMzw==} + cpu: [arm64] + os: [win32] + + lefthook-windows-x64@1.10.9: + resolution: {integrity: sha512-OywJknU5sZiD45ZWoqWbl9GkKoOd2jrdyjuH+jSf5KQn9HnN2Cp4KuVuDOc7MdI0MIN2BYb+Mf8MgmxMWCWt5w==} + cpu: [x64] + os: [win32] + + lefthook@1.10.9: + resolution: {integrity: sha512-UNgvdOMxINultvtDQ0XgqMomMIeI2dyJM5hgOaqpC47SJvVPOy1Mk5i7QnFtfDK/bdB2pKaA61KxrIx6rCmL/w==} + hasBin: true + lilconfig@3.1.3: resolution: {integrity: sha512-/vlFKAoH5Cgt3Ie+JLhRbwOsCQePABiU3tJ1egGvyQ+33R/vcwM2Zl2QR/LzjsBeItPt3oSVXapn+m4nQDvpzw==} engines: {node: '>=14'} @@ -5308,6 +5365,49 @@ snapshots: json-schema: 0.4.0 verror: 1.10.0 + lefthook-darwin-arm64@1.10.9: + optional: true + + lefthook-darwin-x64@1.10.9: + optional: true + + lefthook-freebsd-arm64@1.10.9: + optional: true + + lefthook-freebsd-x64@1.10.9: + optional: true + + lefthook-linux-arm64@1.10.9: + optional: true + + lefthook-linux-x64@1.10.9: + optional: true + + lefthook-openbsd-arm64@1.10.9: + optional: true + + lefthook-openbsd-x64@1.10.9: + optional: true + + lefthook-windows-arm64@1.10.9: + optional: true + + lefthook-windows-x64@1.10.9: + optional: true + + lefthook@1.10.9: + optionalDependencies: + lefthook-darwin-arm64: 1.10.9 + lefthook-darwin-x64: 1.10.9 + lefthook-freebsd-arm64: 1.10.9 + lefthook-freebsd-x64: 1.10.9 + lefthook-linux-arm64: 1.10.9 + lefthook-linux-x64: 1.10.9 + lefthook-openbsd-arm64: 1.10.9 + lefthook-openbsd-x64: 1.10.9 + lefthook-windows-arm64: 1.10.9 + lefthook-windows-x64: 1.10.9 + lilconfig@3.1.3: {} lines-and-columns@1.2.4: {}