Stripes's .eslintrc as an extensible shared config
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.editorconfig
.gitignore
CHANGELOG.md
CONTRIBUTING.md
Jenkinsfile
LICENSE
README.md
index.js
package.json

README.md

eslint-config-stripes

This package provides an extensible shared ESLint config, intended to promote consistent code style among applications built with FOLIO Stripes.

Installation

If you haven't already installed ESLint as a dev dependency in your project, it's a required peer of eslint-config-stripes:

yarn add eslint -D

Then add eslint-config-stripes to your devDependencies:

yarn add eslint-config-stripes -D

Create .eslintrc in the root of your project. Its contents:

{
  "extends": "stripes"
}

Using Babel?

If you're extensively using newer JavaScript syntax with Babel, you may want to use babel-eslint in your FOLIO project.

yarn add babel-eslint -D

In .eslintrc, specify your parser:

{
  "extends": "stripes",
  "parser": "babel-eslint"
}

Usage

Run eslint src in your terminal to lint the files in the src directory (or modify to wherever the primary source of your project lives).

Recommended

Add to your package.json scripts, so you can simply run yarn lint:

"lint": "eslint src"

Additional information

See project STRIPES at the FOLIO issue tracker.

Other FOLIO Developer documentation is at dev.folio.org.