Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

standard --plugin html doesn't seem to work from package.json #1112

Closed
nicolasnoble opened this issue Apr 17, 2018 · 1 comment

Comments

@nicolasnoble
Copy link

commented Apr 17, 2018

I have installed standard and eslint-plugin-html both globally and into my nodejs project. If I run standard --plugin html **/*.html on the command line, this works find. But if I run it from a scripts section of my package.json, I get the following error:

> standard --plugin html **/*.html

standard: Unexpected linter output:

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 (/home/pixel/sources/papan/node_modules/eslint-plugin-html/src/index.js:67:11)
    at Object.<anonymous> (/home/pixel/sources/papan/node_modules/eslint-plugin-html/src/index.js:28:1)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Module.require (module.js:596:17)
    at require (internal/module.js:11:18)
    at Object.load (/home/pixel/sources/papan/node_modules/standard/node_modules/eslint/lib/config/plugins.js:129:26)

If you think this is a bug in `standard`, open an issue: https://github.com/standard/standard/issues

I tried to install the eslint package explicitly too, with no success.

However, using eslint-plugin-html directly with eslint instead of standard works when run from a script section.

@nicolasnoble nicolasnoble referenced this issue Apr 20, 2018
3 of 8 tasks complete
@nicolasnoble

This comment has been minimized.

Copy link
Author

commented Apr 22, 2018

This issue was fixed by upgrading to standard 11.0.1. The rootcause was a mismatch between standard 11.0.1, and the version of eslint that was installed by the eslint-plugin-html package.

@lock lock bot locked as resolved and limited conversation to collaborators Jul 21, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
1 participant
You can’t perform that action at this time.