diff --git a/.eslintrc.js b/.eslintrc.js new file mode 100644 index 0000000..0a8420b --- /dev/null +++ b/.eslintrc.js @@ -0,0 +1,7 @@ +module.exports = { + extends: 'next/core-web-vitals', + rules: { + // Turn off exhaustive-deps rule that's causing most of the warnings + 'react-hooks/exhaustive-deps': 'off' + } +} \ No newline at end of file diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 0000000..f079461 --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,22 @@ +name: Lint + +on: + push: + branches: [main] + pull_request: + branches: [main] + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: 18 + cache: 'npm' + - name: Install dependencies + run: npm ci + - name: Run lint + run: npm run lint \ No newline at end of file diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 0000000..e0944a7 --- /dev/null +++ b/.prettierignore @@ -0,0 +1,11 @@ +# Ignore artifacts +.next +build +node_modules +public +.git +.gitignore +package-lock.json +.DS_Store +# Prisma +prisma/migrations \ No newline at end of file diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000..b43e32e --- /dev/null +++ b/.prettierrc @@ -0,0 +1,9 @@ +{ + "semi": true, + "singleQuote": true, + "tabWidth": 2, + "trailingComma": "es5", + "printWidth": 100, + "bracketSpacing": true, + "arrowParens": "avoid" +} \ No newline at end of file