Skip to content

Commit c95abea

Browse files
authored
Merge pull request #30 from Lab-Lab-Lab/main
Use standard formatting to cleanup source code. use eslint
2 parents d4d10e5 + 4ea0665 commit c95abea

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+2298
-4785
lines changed

.eslintrc.json

+50-39
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,55 @@
11
{
2-
"env": {
3-
"browser": true,
4-
"es2021": true
2+
"env": {
3+
"browser": true,
4+
"es2021": true
5+
},
6+
"extends": [
7+
"plugin:react/recommended",
8+
"airbnb",
9+
"prettier"
10+
],
11+
"parserOptions": {
12+
"ecmaFeatures": {
13+
"jsx": true
514
},
6-
"extends": [
7-
"plugin:react/recommended",
8-
"airbnb",
9-
"prettier"
15+
"ecmaVersion": "latest",
16+
"sourceType": "module"
17+
},
18+
"plugins": [
19+
"react",
20+
"eslint-plugin-prettier"
21+
],
22+
"rules": {
23+
"react/jsx-filename-extension": [
24+
1,
25+
{
26+
"extensions": [
27+
".js",
28+
".jsx"
29+
]
30+
}
1031
],
11-
"parserOptions": {
12-
"ecmaFeatures": {
13-
"jsx": true
14-
},
15-
"ecmaVersion": "latest",
16-
"sourceType": "module"
17-
},
18-
"plugins": [
19-
"react"
32+
"no-console": "off",
33+
"no-unused-vars": "off",
34+
"react/react-in-jsx-scope": "off",
35+
"import/prefer-default-export": "off",
36+
"indent": [
37+
"off",
38+
0
2039
],
21-
"rules": {
22-
"react/jsx-filename-extension": [
23-
1,
24-
{
25-
"extensions": [
26-
".js",
27-
".jsx"
28-
]
29-
}
30-
],
31-
"no-console": "off",
32-
"no-unused-vars": "off",
33-
"react/react-in-jsx-scope": "off",
34-
"indent": [
35-
"warn",
36-
2
37-
],
38-
"react/prop-types": "off",
39-
"default-param-last": "off",
40-
"default-case": "off",
41-
"no-case-declarations": "off",
42-
"jsx-a11y/anchor-is-valid": "off"
43-
}
40+
"react/prop-types": "off",
41+
"default-param-last": "off",
42+
"default-case": "off",
43+
"no-case-declarations": "off",
44+
"jsx-a11y/anchor-is-valid": "off",
45+
"prettier/prettier": [
46+
"error",
47+
{
48+
"singleQuote": true,
49+
"tabWidth": 2,
50+
"semi": true,
51+
"endOfLine": "lf"
52+
}
53+
]
54+
}
4455
}

.github/workflows/node.js.yml

+3-6
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,21 @@ on:
1111

1212
jobs:
1313
build:
14-
runs-on: self-hosted
14+
runs-on: ubuntu-latest
1515

1616
strategy:
1717
matrix:
1818
node-version: [22.x]
1919
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
2020

2121
steps:
22-
- uses: actions/checkout@v2
22+
- uses: actions/checkout@v4
2323
with:
2424
clean: false
2525
- name: Use Node.js ${{ matrix.node-version }}
26-
uses: actions/setup-node@v2
26+
uses: actions/setup-node@v4
2727
with:
2828
node-version: ${{ matrix.node-version }}
2929
cache: 'npm'
3030
- run: npm ci
3131
- run: npm run build --if-present
32-
- run: pm2 reload next-js
33-
env:
34-
CI: true

.vscode/settings.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
{
2-
"editor.defaultFormatter": "esbenp.prettier-vscode",
2+
"[javascript]": { "editor.defaultFormatter": "dbaeumer.vscode-eslint" },
3+
"[javascriptreact]": { "editor.defaultFormatter": "rvest.vs-code-prettier-eslint" },
4+
"[typescript]": { "editor.defaultFormatter": "rvest.vs-code-prettier-eslint" },
35
"editor.formatOnPaste": true,
46
"editor.formatOnSave": true,
57
"editor.formatOnType": true

0 commit comments

Comments
 (0)