mdbetancourt / eslint-plugin-neverthrow

MIT License
44 stars 4 forks source link

Failed to load plugin 'neverthrow' #6

Closed supermacro closed 3 years ago

supermacro commented 3 years ago

I am getting the following error when I run eslint:

> eslint ./src --ext .ts

Oops! Something went wrong! :(

ESLint: 8.2.0

TypeError: Failed to load plugin 'neverthrow' declared in '.eslintrc.js': Class extends value undefined is not a constructor or null

Config

The following is my config:

module.exports = {
  root: true,
  parser: '@typescript-eslint/parser',
  plugins: [
    'neverthrow',
  ],
  extends: [
    'plugin:neverthrow/recommended',
  ],
  rules: {
    'neverthrow/must-use-result': 'error'
  }
};
mdbetancourt commented 3 years ago

Looks like an eslint error I didn't used class, You are missing this options too parserOptions: { ecmaVersion: 2021, project: ['./tsconfig.json'], tsconfigRootDir: __dirname, } EDIT: i just checked and looks like an error with eslint >= 8