mysticatea / eslint-plugin-node

Additional ESLint's rules for Node.js
MIT License
961 stars 171 forks source link

Yarn workspaces with engines in package.json #253

Open rightaway opened 3 years ago

rightaway commented 3 years ago

engines from package.json isn't read by the no-unsupported-features rules when using yarn workspaces. If I set the engines field in the root package.json file (in the same directory that eslintrc file is), the rule still uses the default of >=8.0.0.

michalorman commented 3 years ago

Same for me, I have following in my package.json file:

  "engines": {
    "node": ">=14.0.0"
  },

and still have errors everywhere: error Import and export declarations are not supported yet node/no-unsupported-features/es-syntax.

Ended up disabling this rule completely.

RinkAttendant6 commented 1 year ago

This is a problem with npm workspaces as well with npm 7.x+, not necessarily exclusive to yarn.