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

upgrade node to 20.12.2 #286

Merged
merged 4 commits into from
May 2, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
"default": ["static-field", "instance-field", "constructor", "static-method", "instance-method"]
}
],
"@typescript-eslint/no-parameter-properties": ["warn", { "allows": ["public", "private", "protected"] }],
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/explicit-member-accessibility": "off",
"@typescript-eslint/explicit-function-return-type": "off",
Expand All @@ -44,6 +43,12 @@
"@typescript-eslint/restrict-plus-operands": "off",
"@typescript-eslint/no-floating-promises": "off",
"@typescript-eslint/prefer-regexp-exec": "off",

// Added by Ben while upgrading node
"@typescript-eslint/no-unsafe-argument": "off",
"@typescript-eslint/no-unsafe-enum-comparison": "off",
"@typescript-eslint/no-misused-promises": "off",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just by looking at the name of these tracks, they all sound important. What's the rational of disabling?

Copy link
Author

@bprize15 bprize15 May 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As discussed during standup, I checked which rules would be relatively easy to implement:

Re-enabling @typescript-eslint/no-unsafe-enum-comparison was not too bad so I added that back.

@typescript-eslint/no-unsafe-argument disables the use of any types as arguments, which we do all over the place, so I left it disabled

@typescript-eslint/no-misused-promises checks for multiple conditions, but disallows using async functions as handlers such as many of our onConfirms (since they expect to return void). Thus, I have kept the rule, but disabled errors for that condition. Here is the documentation if interested in checking the other conditions.


"@typescript-eslint/ban-types": [
"error",
{
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/github-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "12.16"
node-version: "20.12.2"
- uses: actions/setup-java@v2
with:
distribution: 'adopt'
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ yarn start
```

yarn is also used to manage CSS and JavaScript dependencies used in this application. You can upgrade dependencies by
specifying a newer version in [package.json](package.json). You can also run `yarn update` and `yarn install` to manage dependencies.
specifying a newer version in [package.json](package.json). You can also run `yarn upgrade` and `yarn install` to manage dependencies.
Add the `help` flag on any command to see how you can use it. For example, `yarn help update`.

The `yarn run` command will list all of the scripts available to run for this project.
Expand Down
4 changes: 3 additions & 1 deletion jest.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ module.exports = {
transform: {
'^.+\\.tsx?$': 'ts-jest',
},
testURL: 'http://localhost/',
testEnvironmentOptions: {
url: 'http://localhost/',
},
cacheDirectory: '<rootDir>/target/jest-cache',
coverageDirectory: '<rootDir>/target/test-results/',
testMatch: ['<rootDir>/src/main/webapp/app/**/@(*.)@(spec.ts?(x))'],
Expand Down
Loading
Loading