Skip to content

Commit 6c5d51b

Browse files
authored
Update ESLint config for TypeScript in README
1 parent 8a17ade commit 6c5d51b

File tree

1 file changed

+5
-13
lines changed

1 file changed

+5
-13
lines changed

README.md

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -133,22 +133,14 @@ For TypeScript:
133133

134134
```js
135135
import js from "@eslint/js";
136+
import tseslint from "typescript-eslint";
136137
import solid from "eslint-plugin-solid/configs/typescript";
137-
import * as tsParser from "@typescript-eslint/parser";
138138

139-
export default [
139+
export default tseslint.config(
140140
js.configs.recommended,
141-
{
142-
files: ["**/*.{ts,tsx}"],
143-
...solid,
144-
languageOptions: {
145-
parser: tsParser,
146-
parserOptions: {
147-
project: "tsconfig.json",
148-
},
149-
},
150-
},
151-
];
141+
tseslint.configs.recommended,
142+
solid,
143+
);
152144
```
153145

154146
These configurations do not configure global variables in ESLint. You can do this yourself manually

0 commit comments

Comments
 (0)