Socket
Book a DemoInstallSign in
Socket

eslint-config-gourmet

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-config-gourmet

ESLint shareable config for the Gourmet style

2.7.1
latest
Source
npmnpm
Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

eslint-config-gourmet

ESLint shareable config for the Gourmet style.

Basic usage

JavaScript format (.eslintrc.js)

module.exports = {
  extends: "gourmet",
  root: true
};

JSON format (.eslintrc.json)

{
  "extends": "gourmet",
  "root": true
}

Configuration sets

You can choose a configuration set based on the type of your target environment by specifying the name after a slash like "gourmet/node".

  • node: Node apps (default)
    • ES2017 syntax (class, async, await, ...)
    • CommonJS (require(), module.exports, ...)
    • No dependency other than a vanilla eslint
  • react: React apps
    • Based on node, additional features as follows:
    • Browser globals (document, window, ...)
    • JSX syntax and React specific rules (react/jsx-uses-react, ...)
    • Requires eslint-plugin-react@7 as a peer dependency
  • gourmet_lib: Gourmet SSR libraries
    • Based on react, additional features as follows:
    • Gourmet SSR specific globals (SERVER, DEBUG, ...)
  • gourmet_app: Gourmet SSR apps
    • Based on gourmet_lib, additional features as follows:
    • Module syntax (import, export, ...)
    • ES proposals (https://github.com/tc39/proposal-class-fields, ...)
    • Requires babel-eslint@10 and eslint-plugin-babel@5 as peer dependencies.

Installing additional packages

As noted above, eslint-config-gourmet requires additional packages per your choice of configuration as below:

# For `react` and `gourmet_lib`
npm install eslint-plugin-react@7 --save-dev

# For `gourmet_app`
npm install eslint-plugin-react@7 babel-eslint@10 eslint-plugin-babel@5 --save-dev

These additional packages are not specified as peerDependencies by eslint-config-gourmet because they are not required for some configurations.

FAQs

Package last updated on 13 Feb 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.