Closed as not planned
Description
Before You File a Documentation Request Please Confirm You Have Done The Following...
- I have looked for existing open or closed documentation requests that match my proposal.
- I have read the FAQ and my problem is not listed.
Suggested Changes
This statement led me to think that I wouldn't need any @stylistic/*
packages and that by using the tseslint.configs.stylisticTypeChecked
config I would get stylistic
lint errors out of the box.
Affected URL(s)
https://typescript-eslint.io/users/configs/#stylistic-type-checked
Additional Info
It may also be worthwhile to provide an example for those looking to use both typescript-eslint
and stylistic
.
It was rather challenging for me to come up with this:
import eslint from "@eslint/js";
import tseslint from "typescript-eslint";
import stylistic from '@stylistic/eslint-plugin-ts'
//import stylisticJsx from '@stylistic/eslint-plugin-jsx'
export default tseslint.config(
eslint.configs.recommended,
tseslint.configs.recommendedTypeChecked,
tseslint.configs.stylisticTypeChecked,
stylistic.configs.all,
{
"languageOptions": {
"parser": tseslint.parser,
"parserOptions": {
//"project": "./tsconfig.json",
"projectService": true,
"tsconfigRootDir": import.meta.dirname
}
},
"plugins": {
"@stylistic/ts": stylistic,
//"@stylistic/jsx": stylisticJsx
}
}
);