Skip to content
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

Added prettier #28

Merged
merged 11 commits into from
Jun 3, 2024
24 changes: 14 additions & 10 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,26 +5,30 @@ module.exports = {
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:react/recommended",
"plugin:@typescript-eslint/recommended"
"plugin:react-hooks/recommended",
"plugin:prettier/recommended"
],
"overrides": [
"plugins": [
"@typescript-eslint",
"react",
"react-hooks",
"prettier"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module"
},
"plugins": [
"react",
"@typescript-eslint"
],
"rules": {
"semi": [2, "always"]
},
"settings": {
"react": {
"version": "^18.2.0"
"version": "detect"
}
},
"rules": {
"prettier/prettier": "error",
"react/prop-types": "off",
"semi": [2, "always"]
}
}
23 changes: 19 additions & 4 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,30 @@
name: Lint
name: Lint and Format

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install modules
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 'lts/*'

- name: Install dependencies
run: npm install
- name: Run linter

- name: Run EsLint
run: npm run lint

- name: Run Prettier
run: npm run format -- --check
Loading
Loading