netlify/eslint-config-node

Feature: Browser/React specific rules

erezrokah opened this issue · 4 comments

We should consider adding a shared configuration for React/Browser applications.

Those might have a set of rules completely different than the ones this library provides, so we can also decide not to have them as a part of this library.

However, having everything at the same place can help with maintenance.

Should we start we something simple like:

  ...overrides,
  {
    files: ['*.jsx'],
    extends: ['eslint:recommended', 'plugin:react/recommended'],
  },

and see how it goes?

I believe ESLint allows shared configuration packages to export several configuration.
We could have a second .eslintrc.js in this repository which extends the first one and adds some React-specific linting. Then, consumers would extends the latter one instead of the former one. What do you think?

I believe ESLint allows shared configuration packages to export several configuration.

Cool I didn't know that.

Then, consumers would extends the latter one instead of the former one. What do you think?

Sounds good

Yes, I think it is possible to extend from a moduleName/filename instead of moduleName. 👍

Closed via #57