Custom ESLint rules for react-expiry
npm install eslint-plugin-react-expiryCustom ESLint rules for react-expiry
You'll first need to install ESLint:
``sh`
npm i eslint --save-dev
Then install this plugin:
`sh`
npm i eslint-plugin-react-expiry --save-dev
Add the following to your .eslintrc file:
`json`
{
"plugins": ["react-expiry"],
"rules": {
"react-expiry/duplicate-id": "error",
"react-expiry/expires-in-past": "error"
}
}
Checks for duplicate id properties in expiry options.
Checks if the expires` property is in the past.
MIT