Separate out an ESLint Shareable Config package #801
Labels
kind: feature
New feature or request
scope: integration
Related to an integration, not necessarily to core (but could influence core)
solution: duplicate
This issue or pull request already exists
Current Behavior
Sometimes I want to use tsdx's wonderful eslint configuration, but don't need the other functions of
tsdx
(build & test), for whatever reason (see comment #634 (comment) for specific examples).One way to do this is to just install the whole
tsdx
package but that will come with a large volume of unused dependencies.Another way to do it is to just use
eslint-config-tsdx
, an eslint shareable config with the rules of tsdx. This way we don't get the large volume of unused dependencies, but that package (right now) just mirrors the configuration that lives intsdx
, and the two can become out-of-sync.Desired Behavior
I would like to be able to install and use just the eslint configuration from tsdx, without the added weight of the other parts of
tsdx
(build & test).I would also like to be sure I'm using the same eslint configuration in this scenario as when using tsdx itself.
Suggested Solution
My proposed solution is simply to use
eslint-config-tsdx
(an eslint shareable config with the rules of tsdx, as mentioned above) here, in theextends
field of the generated eslint config. This way we can achieve both things listed under "Desired Behavior".See #634 (comment) for a more detailed/verbose description of my proposed solution.
I will put my proposed solution into the form of a PR to make it perfectly clear.
Who does this impact? Who is this for?
This is for users who want to use tsdx's linting functionality without using tsdx's other functionalities. This should only impact them; other users should not be impacted at all besides getting a simplified (but equivalent) output from
tsdx lint --write-file
.Describe alternatives you've considered
Some options are described above (under Current Behavior) but have their drawbacks.
Additional context
The use case for this feature is originally described here: #634 (comment)
The text was updated successfully, but these errors were encountered: