npm-check icon indicating copy to clipboard operation
npm-check copied to clipboard

PKG ERR! when extending eslint configs

Open omnidan opened this issue 8 years ago • 11 comments

I have the following .eslintrc in one of my projects:

{
  "extends": "touchlay",
  "env": {
    "node": true
  }
}

Additionally, I have eslint-config-touchlay installed and in package.json:

{
  ...
  "devDependencies": {
    ...
    "eslint-config-touchlay": "^0.2.2",
    ...
  }
}

eslint-config-touchlay has the plugins and other dependencies in its package.json, so they get installed correctly and linting works fine, however, running npm-check does not:

eslint-plugin-react              😟  PKG ERR!  Not in the package.json. Found in: /.eslintrc

eslint-config-standard           😟  PKG ERR!  Not in the package.json. Found in: /.eslintrc

eslint-config-plugin:import      😟  MISSING!  Not installed.
                                 😟  PKG ERR!  Not in the package.json. Found in: /.eslintrc
                                 ⛔️  NPM ERR!  Registry error Package `eslint-config-plugin:import` doesn't exist

eslint-plugin-standard           😟  PKG ERR!  Not in the package.json. Found in: /.eslintrc

eslint-plugin-promise            😟  PKG ERR!  Not in the package.json. Found in: /.eslintrc

Use npm-check -u for interactive update.

It also seems to have a problem (NPM ERR!) with eslint-config-plugin, which uses the following syntax to load the plugin via extends: "plugin:import/errors", "plugin:import/warnings"

omnidan avatar Apr 12 '16 17:04 omnidan

got this too:

eslint-config-plugin:react   😟  MISSING! Not installed.
                             😟  PKG ERR! Not in the package.json. Found in: /.eslintrc.json
                             ⛔  NPM ERR!  Registry error Package `eslint-config-plugin:react` doesn't exi

because my .eslintrc.json says:

{
  "extends": [
    "standard",
    "plugin:react/all"
  ]
}

and note that "plugin:react/all" actually comes from package named "eslint-plugin-react"

benjamine avatar Nov 24 '16 03:11 benjamine

@dylang

septs avatar Dec 17 '16 00:12 septs

@dylang Do we have any progress here?

StyleT avatar Feb 15 '17 11:02 StyleT

@LinusU

StyleT avatar Mar 13 '17 15:03 StyleT

@StyleT I would recommend making a PR to this PR, which adds tests to this project

amilajack avatar Mar 13 '17 16:03 amilajack

This is still an outstanding issue.

https://eslint.org/docs/user-guide/configuring#extending-configuration-files

	extends: [
		'plugin:node/recommended'
	],

screen shot 2017-11-02 at 11 41 36 am

fluxsauce avatar Nov 02 '17 18:11 fluxsauce


eslint-config-plugin:react   😟  MISSING!  Not installed.
                             😟  PKG ERR!  Not in the package.json. Found in: /.eslintrc
                             ⛔️  NPM ERR!  Registry error Package `eslint-config-plugin:react` doesn't exist

Any chance this will get fixed soon?

natorojr avatar Mar 14 '18 21:03 natorojr

Any chance that this will be considered to be fixed or not?

ppsx avatar May 29 '18 13:05 ppsx

Noticing this as well.....

jakeleventhal avatar Feb 29 '20 23:02 jakeleventhal

Maintainer of depcheck here, surely the culprit for this issue.

Any chance that this will be considered to be fixed or not?

There is 100% chance it will be done if you open a PR yes.

I will take a look on my side and make a PR here to update the dependency

rumpl avatar Mar 02 '20 09:03 rumpl

@rumpl was this ever fixed?

jakeleventhal avatar May 23 '20 18:05 jakeleventhal