isaacscript-lint 4.16.0 → 4.16.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -71,9 +71,9 @@ pnpm install isaacscript-lint --save-dev
|
|
|
71
71
|
|
|
72
72
|
(It should be a development dependency because it is only used to lint your code pre-production.)
|
|
73
73
|
|
|
74
|
-
### Step 2 -
|
|
74
|
+
### Step 2 - `.eslintrc.cjs`
|
|
75
75
|
|
|
76
|
-
Create a
|
|
76
|
+
Create a `.eslintrc.cjs` file in the root of your repository:
|
|
77
77
|
|
|
78
78
|
```js
|
|
79
79
|
// This is the configuration file for ESLint, the TypeScript linter:
|
|
@@ -98,6 +98,8 @@ module.exports = {
|
|
|
98
98
|
};
|
|
99
99
|
```
|
|
100
100
|
|
|
101
|
+
Note that this file must have a period at the beginning!
|
|
102
|
+
|
|
101
103
|
### Step 3 - `tsconfig.eslint.json`
|
|
102
104
|
|
|
103
105
|
Create a `tsconfig.eslint.json` file in the root of your repository:
|
|
@@ -166,6 +168,16 @@ In order for the linter to work inside of VSCode, you will have to install the f
|
|
|
166
168
|
- [Prettier](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode)
|
|
167
169
|
- [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint)
|
|
168
170
|
|
|
171
|
+
Additionally, you might also want to install the CSpell extension, which is extremely useful to spell check an entire code base:
|
|
172
|
+
|
|
173
|
+
- [CSpell](https://marketplace.visualstudio.com/items?itemName=streetsidesoftware.code-spell-checker)
|
|
174
|
+
|
|
175
|
+
Once installed, these extensions provide the a nice dichotomy:
|
|
176
|
+
|
|
177
|
+
- Red squiggly underlines are type-errors from the TypeScript compiler.
|
|
178
|
+
- Yellow squiggly underlines are warnings from ESLint. (Our config uses `eslint-plugin-only-warn` to convert all ESLint errors to warnings.)
|
|
179
|
+
- Blue squiggly underlines are misspelled words. (You can right click --> `Spelling` --> `Add Words to CSpell Configuration` to ignore a specific word.)
|
|
180
|
+
|
|
169
181
|
#### `.vscode/settings.json`
|
|
170
182
|
|
|
171
183
|
Furthermore, you will probably want Prettier and ESLint to be run automatically every time you save a TypeScript file. You can tell VSCode to do this by adding the following to your project's `.vscode/settings.json` file:
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "isaacscript-lint",
|
|
3
|
-
"version": "4.16.
|
|
3
|
+
"version": "4.16.2",
|
|
4
4
|
"description": "A linting dependency meta-package for IsaacScript and TypeScript projects.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"isaacscript",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"eslint-plugin-deprecation": "^1.3.3",
|
|
36
36
|
"eslint-plugin-eslint-comments": "^3.2.0",
|
|
37
37
|
"eslint-plugin-import": "^2.27.5",
|
|
38
|
-
"eslint-plugin-isaacscript": "^2.6.
|
|
38
|
+
"eslint-plugin-isaacscript": "^2.6.2",
|
|
39
39
|
"eslint-plugin-jsdoc": "^40.0.0",
|
|
40
40
|
"eslint-plugin-n": "^15.6.1",
|
|
41
41
|
"eslint-plugin-no-autofix": "^1.2.3",
|