eslint-plugin-jsonc
eslint-plugin-jsonc copied to clipboard
Resolve other plugins as siblings to this plugin
Why do I want this? I have a monorepo with the current file structure:
apps/
- app1/
- package.json
.............
- app127/
- package.json
packages/
- package1/
- package.json
............
- package453/
- package.json
repotools/
- central-linter/
- package.json
.eslintrc.json
.eslintignore
I want to install eslint and all of its configs and plugins into the repotools/central-linter/node_modules. I do not want to install a separate copy of eslint and its plugins in each app/package. Also note that there is no package.json file at the root of the repo because I have lots of issues with npm workspaces.
I also want to keep the .eslintrc.json and .eslintignore files at the root of the monorepo for better IDE integration.
I am able to accomplish all of this except for this eslint-plugin-jsonc
since this plugin keeps trying to load plugins relative to the root of the monorepo, rather than the resolvePluginsRelativeTo
that I passed to my central linter.
This PR should modify the behavior of eslint-plugin-jsonc
to always resolve plugins relative to itself.
P.S. I cannot upgrade to ESLint v9 yet because nx
and eslint-plugin-react
does not support ESLint v9 yet.
🦋 Changeset detected
Latest commit: d1728a90cd7dce5d2b785a10400b36e2c8e619eb
The changes in this PR will be included in the next version bump.
This PR includes changesets to release 1 package
Name | Type |
---|---|
eslint-plugin-jsonc | Minor |
Not sure what this means? Click here to learn what changesets are.
Click here if you're a maintainer who wants to add another changeset to this PR
@ota-meshi Whenever you get a chance, could you please take a look at this PR? Thank you!