eslint-config-apteryx

2.1.8 • Public • Published

Apteryx's ESLint Config

Installation

npm install eslint eslint-config-apteryx
yarn add eslint eslint-config-apteryx
pnpm add eslint eslint-config-apteryx

Any additional dependencies - based on which configurations you decide to use - will automatically be installed upon your first run of ESLint.

Usage

This package includes the following configurations:

Configuration

Node.js
{
    "root": true,
    "extends": [
        "apteryx/common",
        "apteryx/node",
        "apteryx/typescript",
        "apteryx/prettier"
    ],
    "parserOptions": {
        "project": "./tsconfig.json"
    },
    "ignorePatterns": ["**/dist/*"]
}

React / Next
{
    "root": true,
    "extends": [
        "apteryx/common",
        "apteryx/browser",
        "apteryx/node",
        "apteryx/typescript",
        "apteryx/next",
        "apteryx/prettier"
    ],
    "parserOptions": {
        "project": "./tsconfig.json"
    },
    "ignorePatterns": ["**/dist/*"],
    "rules": {
        "react/react-in-jsx-scope": 0,
        "react/jsx-filename-extension": [1, { "extensions": [".tsx"] }]
    }
}

Usage with Prettier

Use with prettier-config-apteryx.

{
    "extends": [
        "apteryx/common",
        "apteryx/node",
        "apteryx/typescript",
        "apteryx/prettier"
    ]
}

apteryx/prettier must be last in the list, as this will disable all other rules that conflict with Prettier.

Package Sidebar

Install

npm i eslint-config-apteryx

Weekly Downloads

1

Version

2.1.8

License

MIT

Unpacked Size

51.8 kB

Total Files

12

Last publish

Collaborators

  • apteryxxyz