Support TypeScript linting
See original GitHub issueNow that kcd-scripts
supports building TypeScript (see https://github.com/kentcdodds/kcd-scripts/pull/131 & https://github.com/kentcdodds/kcd-scripts/pull/133), eslint-config-kentcdodds
should be able to lint TypeScript (like @KubaJastrz said):
Also, I think that
kcd-scripts lint
will fail on TypeScript files when using the default configuration. https://github.com/kentcdodds/eslint-config-kentcdodds should also be updated.
I wanted to first open this issue so we can discuss how we would handle it.
In my opinion we have 3 options:
- Add a
kentcdodds/typescript
config, like we already have forreact
,jest
, … This is how most other configs are doing it (seeplugin:import/typescript
,prettier/@typescript-eslint
, …) This means we need to check in some way whetherreact
/jest
/… is used, because overriding rules from those configs without using them will throw an error. - Add
kentcdodds/react-typescript
/kentcdodds/jest-typescript
/… configs that extend the normal configs and override the necessary rules - Automatically check if
typescript
is a dependency and add rule overrides in the already existing configs
I’m in favor of 2 or 3, but I’m happy to hear your thoughts @kentcdodds. 🙂
Issue Analytics
- State:
- Created 3 years ago
- Comments:13 (6 by maintainers)
Top Results From Across the Web
How to use ESLint with TypeScript | Khalil Stemmler
ESLint is a JavaScript linter that enables you to enforce a set of style, formatting, and coding standards for your codebase. It looks...
Read more >Linting in TypeScript using ESLint and Prettier - LogRocket Blog
One of the most popular tools for linting is ESLint, which will analyze your code to find potential bugs and improve your code...
Read more >typescript-eslint
ESLint statically analyzes your code to quickly find problems. It allows creating a series of assertions called lint rules around what your code...
Read more >Linting TypeScript | WebStorm Documentation - JetBrains
The recommended linter for TypeScript code is ESLint which brings a wide range of linting rules that can also be extended with plugins....
Read more >TSLint - Palantir Open Source
TSLint is an extensible static analysis tool that checks TypeScript code for readability, maintainability, and functionality errors. It is widely supported ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Let’s revive this 😃 I’m building something with TypeScript right now and would love to have better linting support. I’ll probably work on this sometime later if nobody gets to it before me.
Just to be sure I understand correctly:
overrides
is the same asextends
, but for specific globs right? 🤔 You don’t have a ‘clean slate’ when usingoverrides
, right? 🤔