@inventi/eslint-plugin-reinhard

1.2.2 • Public • Published

@inventi/eslint-plugin-reinhard

Grammar nazi for your INVENTI grab a plate project.

This ESLint plugin enforces the Frontend Principles.

Installation

Assuming you already have ESLint installed, run:

# npm
npm install @inventi/eslint-plugin-reinhard --save-dev

# yarn
yarn add @inventi/eslint-plugin-reinhard --dev

Then extend the recommended eslint config:

{
  "extends": [
    // ...
    "plugin:@inventi/reinhard/recommended"
  ]
}

Custom Configuration

If you want more fine-grained configuration, you can instead add a snippet like this to your ESLint configuration file:

{
  "plugins": [
    // ...
    "@inventi/reinhard"
  ],
  "rules": {
    // ...
    '@inventi/reinhard/no-data-hooks-inside-components': ['error'], // disallow hooks for fetching and mutating data inside regular presentational components
    '@inventi/reinhard/no-data-hooks-in-basic-components-dirs': ['error'], // disallow hooks within components directories
    '@inventi/reinhard/components-staff-culture': ['error'], // staff culture of components; every component should consist of  index.ts, storybook and component
  }
}

License

MIT

Development

yarn remove @inventi/eslint-plugin-reinhard yarn add --dev file:./src/@packages/eslintPluginReinhard

Add plugin to eslint config - see section Custom Configuration above

Readme

Keywords

none

Package Sidebar

Install

npm i @inventi/eslint-plugin-reinhard

Weekly Downloads

28

Version

1.2.2

License

MIT

Unpacked Size

8.97 kB

Total Files

4

Last publish

Collaborators

  • adambisek