EsLint couldn't find the plugin "eslint-plugin-html"
See original GitHub issueDescription
There’s an error when run yarn run lint
or npm run lint
:
EsLint couldn't find the plugin "eslint-plugin-html".
Steps to reproduce
- Clone react-boilerplate project with command
git clone --depth=1 https://github.com/react-boilerplate/react-boilerplate.git
- Run command to setup:
npm run setup
- Enter to remove old repo
- Run linting:
yarn run lint
then get issue below:
$ yarn run lint
yarn run v1.5.1
$ npm run lint:js
> react-boilerplate@3.5.0 lint:js /Users/dungla4/workspace/app-react-boilerplate
> npm run lint:eslint -- .
> react-boilerplate@3.5.0 lint:eslint /Users/dungla4/workspace/app-react-boilerplate
> eslint --ignore-path .gitignore --ignore-pattern internals/scripts "."
Oops! Something went wrong! :(
ESLint couldn't find the plugin "eslint-plugin-html". This can happen for a couple different reasons:
1. If ESLint is installed globally, then make sure eslint-plugin-html is also installed globally. A globally-installed ESLint cannot find a locally-installed plugin.
2. If ESLint is installed locally, then it's likely that the plugin isn't installed correctly. Try reinstalling by running the following:
npm i eslint-plugin-html@latest --save-dev
Actually we don’t use eslint-plugin-html
for react project, this error is too strange. However I try to install eslint-plugin-html
(latest is 4.0.2)
After installing, I got another issue:
$ yarn run lint
yarn run v1.5.1
$ npm run lint:js
> react-boilerplate@3.5.0 lint:js /Users/dungla4/workspace/app-react-boilerplate
> npm run lint:eslint -- .
> react-boilerplate@3.5.0 lint:eslint /Users/dungla4/workspace/app-react-boilerplate
> eslint --ignore-path .gitignore --ignore-pattern internals/scripts "."
eslint-plugin-html error: It seems that eslint is not loaded. If you think it is a bug, please file a report at https://github.com/BenoitZugmeyer/eslint-plugin-html/issues
Error: eslint-plugin-html error: It seems that eslint is not loaded. If you think it is a bug, please file a report at https://github.com/BenoitZugmeyer/eslint-plugin-html/issues
at iterateESLintModules (/Users/dungla4/workspace/app-react-boilerplate/node_modules/eslint-plugin-html/src/index.js:65:11)
at Object.<anonymous> (/Users/dungla4/workspace/app-react-boilerplate/node_modules/eslint-plugin-html/src/index.js:26:1)
at Module._compile (module.js:649:30)
at Object.Module._extensions..js (module.js:660:10)
at Module.load (module.js:561:32)
at tryModuleLoad (module.js:501:12)
at Function.Module._load (module.js:493:3)
at Module.require (module.js:593:17)
at require (internal/module.js:11:18)
at Object.load (/Users/dungla4/workspace/app-react-boilerplate/node_modules/eslint/lib/config/plugins.js:129:26)
Versions
- React-Boilerplate (see
package.json
): 3.5.0 - Node/NPM: v9.10.1/5.6.0
- Browser: N/A
I also tried to downgrade node to v8 but same error
There’s no eslint
global (yarn and npm)
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
ESLint couldn't find the plugin "eslint-plugin-@typescript-eslint"
Missing . eslintrc config file from the project folder. Solution: npx eslint --init. Additional node_modules folder in the project-parent ...
Read more >eslint/eslint - Gitter
ESLint couldn't find the plugin "eslint-plugin-react-hooks". This can happen for a couple different reasons: 1. If ESLint is installed globally, then make sure ......
Read more >eslint-plugin-html - npm
This plugin focuses on applying ESLint rules on inline scripts contained in HTML. It does not provide any rule related to HTML. For...
Read more >Working with Plugins - ESLint - Pluggable JavaScript Linter
To use the rule in ESLint, you would use the unprefixed plugin name, followed by a slash, followed by the rule name. So...
Read more >User Guide | eslint-plugin-vue
Make sure you don't have eslint-plugin-html in your config. The eslint-plugin-html extracts ...
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 Free
Top 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
I found the root cause 😦 There’s an
.eslintrc
in parent folder of my project. That’s why eslint always notify error. After deleting file, everything is ok. Close this issue. Thank you very much @gretzkyThis thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.