Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 0
feat: tooling (ts, lint, format, commit hook)#3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uh oh!
There was an error while loading. Please reload this page.
Changes from all commits
7afb39295ceff951e78f0ef5355a88c18ee999fbea8da03ac811d54dd32ea5bFile filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| pnpm lint-staged |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| { | ||
| "semi": true, | ||
| "singleQuote": false, | ||
| "printWidth": 80, | ||
| "plugins": ["prettier-plugin-astro", "prettier-plugin-tailwindcss"], | ||
| "overrides": [ | ||
| { | ||
| "files": "*.astro", | ||
| "options": { | ||
| "parser": "astro" | ||
| } | ||
| } | ||
| ] | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,9 @@ | ||
| { | ||
| "recommendations": ["astro-build.astro-vscode"], | ||
| "recommendations": [ | ||
| "astro-build.astro-vscode", | ||
| "esbenp.prettier-vscode", | ||
| "dbaeumer.vscode-eslint", | ||
| "oxc.oxc-vscode" | ||
| ], | ||
| "unwantedRecommendations": [] | ||
| } | ||
wiktoriavh marked this conversation as resolved.
Uh oh!There was an error while loading. Please reload this page. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| { | ||
| "explorer.fileNesting.enabled": true, | ||
| "explorer.fileNesting.patterns": { | ||
| "package.json": "package-lock.json, pnpm*, .yarnrc*, yarn*, .eslint*, eslint*, .oxlint*, oxlint*, .prettier*, prettier*, .editorconfig" | ||
| }, | ||
| "editor.codeActionsOnSave": { | ||
| "source.fixAll": "explicit", | ||
| "source.organizeImports": "explicit" | ||
| }, | ||
| "editor.formatOnSave": true, | ||
| "editor.defaultFormatter": "esbenp.prettier-vscode", | ||
| "oxc.enable": true | ||
| } |
This file was deleted.
Uh oh!
There was an error while loading. Please reload this page.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| import js from "@eslint/js"; | ||
| import astroParser from "astro-eslint-parser"; | ||
| import prettierConfig from "eslint-config-prettier"; | ||
| import astro from "eslint-plugin-astro"; | ||
| import oxlint from "eslint-plugin-oxlint"; | ||
| import { defineConfig } from "eslint/config"; | ||
| import tseslint from "typescript-eslint"; | ||
| export default defineConfig([ | ||
| js.configs.recommended, | ||
| ...tseslint.configs.recommended, | ||
| ...astro.configs.recommended, | ||
| ...oxlint.configs["flat/recommended"], | ||
| prettierConfig, | ||
| { | ||
| ignores: [ | ||
| "dist/", | ||
| ".astro/", | ||
| "node_modules/", | ||
| "pnpm-lock.yaml", | ||
| ".vscode/", | ||
| ".husky/", | ||
| ".cursor/", | ||
| "terraform/", | ||
| ], | ||
| }, | ||
| { | ||
| files: ["**/*.{mjs,js,cjs}"], | ||
| languageOptions: { | ||
| globals: { | ||
| process: "readonly", | ||
| }, | ||
| }, | ||
| }, | ||
| { | ||
| files: ["**/*.astro"], | ||
| languageOptions: { | ||
| parser: astroParser, | ||
| parserOptions: { | ||
| parser: tseslint.parser, | ||
| extraFileExtensions: [".astro"], | ||
| sourceType: "module", | ||
| }, | ||
| }, | ||
| }, | ||
| ]); |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -8,23 +8,31 @@ | ||
| }, | ||
| "scripts": { | ||
| "dev": "astro dev", | ||
| "build": "astro build", | ||
| "build": "astro check && astro build", | ||
| "preview": "astro preview", | ||
| "astro": "astro", | ||
| "lint": "eslint .", | ||
| "lint:eslint": "eslint . --fix", | ||
| "lint:oxlint": "oxlint . --fix", | ||
| "lint": "pnpm lint:eslint && pnpm lint:oxlint", | ||
| "test": "vitest", | ||
| "test:run": "vitest run", | ||
| "test:coverage": "vitest run --coverage" | ||
| "typecheck": "astro check", | ||
| "test:coverage": "vitest run --coverage", | ||
| "format": "prettier . --write", | ||
| "prepare": "husky" | ||
| }, | ||
| "dependencies": { | ||
| "@astrojs/check": "^0.9.9", | ||
| "@astrojs/react": "^5.0.7", | ||
| "@astrojs/ts-plugin": "^1.10.9", | ||
| "@tailwindcss/vite": "^4.3.0", | ||
| "@types/react": "^19.2.17", | ||
| "@types/react-dom": "^19.2.3", | ||
| "astro": "^6.4.4", | ||
| "react": "^19.2.7", | ||
| "react-dom": "^19.2.7", | ||
| "tailwindcss": "^4.3.0", | ||
| "typescript": "^6.0.3", | ||
| "zod": "^4.4.3" | ||
| }, | ||
| "devDependencies": { | ||
| @@ -34,11 +42,30 @@ | ||
| "@testing-library/jest-dom": "^6.9.1", | ||
| "@testing-library/react": "^16.3.2", | ||
| "@testing-library/user-event": "^14.6.1", | ||
| "@types/node": "^25.9.3", | ||
| "astro-eslint-parser": "^1.4.0", | ||
| "eslint": "^10.4.1", | ||
| "eslint-config-prettier": "^10.1.8", | ||
| "eslint-plugin-astro": "^1.7.0", | ||
| "eslint-plugin-oxlint": "^1.69.0", | ||
| "husky": "^9.1.7", | ||
| "jsdom": "^29.1.1", | ||
| "lint-staged": "^17.0.7", | ||
| "oxlint": "^1.69.0", | ||
wiktoriavh marked this conversation as resolved.
Uh oh!There was an error while loading. Please reload this page. | ||
| "prettier": "^3.8.4", | ||
| "prettier-plugin-astro": "^0.14.1", | ||
| "prettier-plugin-tailwindcss": "^0.8.0", | ||
| "sharp": "^0.34.5", | ||
| "typescript-eslint": "^8.61.0", | ||
| "vitest": "^4.1.8" | ||
| }, | ||
| "lint-staged": { | ||
| "*.{js,ts,mjs,cjs}": [ | ||
| "eslint --fix", | ||
| "prettier --write" | ||
| ], | ||
| "*.{astro,json,md,yml,yaml}": [ | ||
| "prettier --write" | ||
| ] | ||
| } | ||
| } | ||
| } | ||
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.