## Description Make eslint rules stricter for packages #### Type of change - Chore (housekeeping or task changes that don't impact user perception) ## Testing > #### How Has This Been Tested? > Please describe the tests that you ran to verify your changes. Also list any relevant details for your test configuration. > Delete anything that is not relevant - [x] Manual - [x] Jest - [ ] Cypress ## Checklist: #### Dev activity - [x] My code follows the style guidelines of this project - [x] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [ ] I have made corresponding changes to the documentation - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works - [x] New and existing unit tests pass locally with my changes - [ ] PR is being merged under a feature flag Co-authored-by: Valera Melnikov <melnikov.vv@greendatasoft.ru>
14 lines
508 B
TypeScript
14 lines
508 B
TypeScript
/// <reference types="@welldone-software/why-did-you-render" />
|
|
// ^ https://github.com/welldone-software/why-did-you-render/issues/161
|
|
import React from "react";
|
|
|
|
if (process.env.NODE_ENV === "development") {
|
|
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
const whyDidYouRender = require("@welldone-software/why-did-you-render");
|
|
whyDidYouRender(React, {
|
|
trackAllPureComponents: false,
|
|
trackExtraHooks: [[require("react-redux/lib"), "useSelector"]],
|
|
});
|
|
}
|
|
export default "";
|