Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

eslint: Refactor eslint-loader and eslintrc config generation #1182

Merged
merged 1 commit into from
Oct 21, 2018
Merged

eslint: Refactor eslint-loader and eslintrc config generation #1182

merged 1 commit into from
Oct 21, 2018

Commits on Oct 21, 2018

  1. eslint: Refactor eslint-loader and eslintrc config generation

    * Adds option validation to `@neutrinojs/eslint`, so that it now
      throws when passed options that are not supported by eslint-loader.
    * The eslintrc conversion now correctly handles all supported options
      under `baseConfig` rather than silently ignoring them.
    * The eslintrc conversion no longer looks for settings in locations
      that are invalid for eslint-loader (such as top-level `settings`,
      `extends`, `root` or `overrides` options).
    * The eslintrc conversion now no longer errors if passed options that
      were previously missing from the `omit()` list, such as `ignore`
      and `reportUnusedDisableDirectives`.
    * The custom lint `merge()` function has been replaced with ESLint's
      own merging function, which correctly handles several cases that
      were broken before.
    * All non-loader related configuration has now been moved under the
      `baseConfig` key, since the options under it more closely relate
      to the options that users will have previously seen in `.eslintrc`
      files, thereby reducing user-confusion and making it possible to
      copy and paste the contents of the `baseConfig` section to a static
      `.eslintrc.*`.
    * Support has been added for projects that want to use their own
      non-generated `.eslintrc.*` file. They now only need to set
      `useEslintrc` to `true`, which will make the linting presets only
      set the loader-related options, preventing conflicts with the
      options set in their static `.eslintrc.*` file.
    * The `@neutrinojs/loader-merge` middleware has been removed, since
      its functionality was not sufficient for merging lint configuration
      correctly, and was not used for any other purpose.
    
    Fixes #1181.
    Fixes #382.
    edmorley committed Oct 21, 2018
    Configuration menu
    Copy the full SHA
    175a964 View commit details
    Browse the repository at this point in the history