eslint-plugin-react-hmr-export-checker

0.1.4 • Public • Published

eslint-plugin-react-hmr-export-checker

npmV githubLastCommit npmDM

Only export react components or typescript functions/variables.

WARNING i made this rule because my hmr was broken, i probably have not thought about all possible scenarios so it might not work correctly.

WARNING default export with other exports are not allowed/supported because im to lazy to implement it.

Installation

You'll first need to install ESLint:

npm i eslint --save-dev

Next, install eslint-plugin-react-hmr-export-checker:

npm install eslint-plugin-react-hmr-export-checker --save-dev

Usage

Add react-hmr-export-checker to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:

{
    "plugins": [
        "react-hmr-export-checker"
    ]
}

Then configure the rules you want to use under the rules section.

{
    "rules": {
        "react-hmr-export-checker/rule-name": 2
    }
}

Supported Rules

  • Fill in provided rules here

  • only-export-react-components

Copyright (c) 2022 Leonard Grosoli Licensed under the MIT license.

Package Sidebar

Install

npm i eslint-plugin-react-hmr-export-checker

Weekly Downloads

2

Version

0.1.4

License

MIT

Unpacked Size

18.6 kB

Total Files

10

Last publish

Collaborators

  • the_real_syler