Giter Club home page Giter Club logo

rollup-plugin-eslint's Introduction

@rbnlffl/rollup-plugin-eslint

latest version on npm npm downloads a month required node version dependency status eslint dependency rollup peer dependency package license

Lint your Rollup bundles with ESLint. ๐Ÿ

Nicely integrates the most recent version of eslint into a rollup plugin.

How

yarn add @rbnlffl/rollup-plugin-eslint --dev
import eslint from '@rbnlffl/rollup-plugin-eslint';

export default {
  // ..
  plugins: [
    eslint()
    // ..
  ]
};

Config

This plugin respects your ESLint configuration as per default. It also takes a configuration object intended for the ESLint constructor with the addition of a throwOnWarning, throwOnError, filterInclude and filterExclude prop. The most popular configuration options are as follows:

fix

Type: boolean
Default: false
Utilized by: ESLint constructor

Controls whether to enable or disable the autofix feature of ESLint.

extensions

Type: string[]
Default: null
Utilized by: ESLint constructor

Controls what type of files ESLint should look at. The default of null is equal to [ '.js' ].

throwOnWarning

Type: boolean
Default: false
Utilized by: The plugin itself

Controls whether or not to throw an error and exit the process when ESLint reports any warnings.

throwOnError

Type: boolean
Default: false
Utilized by: The plugin itself

Controls whether or not to throw an error and exit the process when ESLint reports any errors.

filterInclude

Type: string or string[]
Default: undefined
Utilized by: createFilter plugin

A single picomatch pattern or an array of patterns controlling which files this plugin should explicitly include. Gets forwarded to the createFilter plugin.

filterExclude

Type: string or string[]
Default: 'node_modules/**'
Utilized by: createFilter plugin

A single picomatch pattern or an array of patterns controlling which files this plugin should explicitly exclude. Gets forwarded to the createFilter plugin, resulting in the matching files being completely skipped.

Why a new plugin?

Because rollup-plugin-eslint seems to be dead and relies on eslint^6.0.0, which resolves to v6.8.0, resulting in unexpected errors when using rules introduced in versions 7 and up.

License

MIT

rollup-plugin-eslint's People

Contributors

robinloeffel avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.