question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

eslint-plugin-html error: It seems that eslint is not loaded.

See original GitHub issue

I upgraded to eslint 4.0 the other day and received this error. I figured a version compatible plugin update was coming. I saw today a v3 release, so I upgraded. I’m getting the same error.

It’s very possible this is related to the vue plugin or eslint, but due to the error message, I thought I would start here.

Error Message

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/alex/dev/projects/artisanhd-v2/node_modules/eslint-plugin-vue/node_modules/eslint-plugin-html/src/index.js:65:11)
    at Object.<anonymous> (/Users/alex/dev/projects/artisanhd-v2/node_modules/eslint-plugin-vue/node_modules/eslint-plugin-html/src/index.js:36:1)
    at Module._compile (module.js:569:30)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:503:32)
    at tryModuleLoad (module.js:466:12)
    at Function.Module._load (module.js:458:3)
    at Module.require (module.js:513:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/Users/alex/dev/projects/artisanhd-v2/node_modules/eslint-plugin-vue/index.js:3:1)
error Command failed with exit code 1.

Run Command

eslint --ext vue ./src/js

.eslintrc.json

{
    "root": true,
    "env": {
        "browser": true,
        "node": true
    },
    "plugins": ["vue", "html"],
    "extensions": ["vue"],
    "settings": {
        "html/html-extensions": [".html", ".vue", ".php", ".twig"]
    },
    "parserOptions": {
        "ecmaVersion": 2017,
        "sourceType": "module",
        "ecmaFeatures": {
            "impliedStrict": true,
            "experimentalObjectRestSpread": true,
            "jsx": true
        }
    },
    "globals": {
        "ajax": true,
        "axios": true,
        "Tether": true,
        "Promise": true
    },
    "extends": "eslint:recommended",
    "rules": {
        "indent": ["error", 4, {
            "SwitchCase": 1
        }],
        "linebreak-style": ["error", "unix"],
        "semi": ["error", "never"],
        "comma-dangle": ["warn", {
            "arrays": "ignore",
            "objects": "ignore",
            "imports": "ignore",
            "exports": "ignore",
            "functions": "never"
        }],
        "comma-style": ["error", "last"],
        "computed-property-spacing": ["error", "never"],
        "no-console": ["error", { "allow": ["warn", "error"] }],
        "no-alert": "error",
        "no-dupe-args": "error",
        "no-duplicate-case": "error",
        "no-duplicate-imports": "error",
        "no-empty": "error"
    }
}

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:13 (3 by maintainers)

github_iconTop GitHub Comments

6reactions
BenoitZugmeyercommented, Jun 14, 2017

ESLint v4 is only supported by eslint-plugin-html v3, so you can’t use eslint-plugin-html v1.5.2 with it (I should add a warning about this when trying to use the plugin with an incompatible version on ESLint).

If you do not use ESLint v4, please provide more information (package.json, a gist to reproduce, …)

2reactions
lpcmancommented, Mar 28, 2018

upgrade local eslint from 3.19.0 to 4.19.1 solved my problem, eslint-plugin-html is 4.0.1.

Read more comments on GitHub >

github_iconTop Results From Across the Web

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.
Read more >
visual studio code - eslint not running for html files
Everything is working fine when I manually pass the .html file to eslint CLI, thus I gusss it's not an issue with the...
Read more >
eslint/eslint - Gitter
Hello, I am trying with setting up new electron-vue project and getting below error: ESLint couldn't find the plugin "eslint-plugin-html".
Read more >
User Guide | eslint-plugin-vue
Official ESLint plugin for Vue.js.
Read more >
ESLint | WebStorm Documentation - JetBrains
WebStorm integrates with ESLint which brings a wide range of linting rules that can also be extended with plugins.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found