2024-07-19 20:17:57 +03:00
|
|
|
import {
|
|
|
|
RULE_NAME as injectWorkspaceRepositoryName,
|
|
|
|
rule as injectWorkspaceRepository,
|
|
|
|
} from './rules/inject-workspace-repository';
|
2024-01-04 01:07:25 +03:00
|
|
|
import {
|
|
|
|
rule as componentPropsNaming,
|
|
|
|
RULE_NAME as componentPropsNamingName,
|
|
|
|
} from './rules/component-props-naming';
|
|
|
|
import {
|
|
|
|
rule as effectComponents,
|
|
|
|
RULE_NAME as effectComponentsName,
|
|
|
|
} from './rules/effect-components';
|
2024-03-09 12:48:19 +03:00
|
|
|
import {
|
|
|
|
rule as explicitBooleanPredicatesInIf,
|
|
|
|
RULE_NAME as explicitBooleanPredicatesInIfName,
|
|
|
|
} from './rules/explicit-boolean-predicates-in-if';
|
2024-01-04 01:07:25 +03:00
|
|
|
import {
|
|
|
|
rule as matchingStateVariable,
|
|
|
|
RULE_NAME as matchingStateVariableName,
|
|
|
|
} from './rules/matching-state-variable';
|
2024-02-25 15:52:48 +03:00
|
|
|
import {
|
|
|
|
rule as maxConstsPerFile,
|
|
|
|
RULE_NAME as maxConstsPerFileName,
|
|
|
|
} from './rules/max-consts-per-file';
|
2024-01-04 01:07:25 +03:00
|
|
|
import {
|
|
|
|
rule as noHardcodedColors,
|
|
|
|
RULE_NAME as noHardcodedColorsName,
|
|
|
|
} from './rules/no-hardcoded-colors';
|
2024-06-04 18:04:57 +03:00
|
|
|
import {
|
|
|
|
rule as noNavigatePreferLink,
|
|
|
|
RULE_NAME as noNavigatePreferLinkName,
|
|
|
|
} from './rules/no-navigate-prefer-link';
|
2024-01-04 01:07:25 +03:00
|
|
|
import {
|
|
|
|
rule as noStateUseref,
|
|
|
|
RULE_NAME as noStateUserefName,
|
|
|
|
} from './rules/no-state-useref';
|
|
|
|
import {
|
|
|
|
rule as sortCssPropertiesAlphabetically,
|
|
|
|
RULE_NAME as sortCssPropertiesAlphabeticallyName,
|
|
|
|
} from './rules/sort-css-properties-alphabetically';
|
|
|
|
import {
|
|
|
|
rule as styledComponentsPrefixedWithStyled,
|
|
|
|
RULE_NAME as styledComponentsPrefixedWithStyledName,
|
|
|
|
} from './rules/styled-components-prefixed-with-styled';
|
2024-03-06 02:24:20 +03:00
|
|
|
import {
|
|
|
|
rule as useGetLoadableAndGetValueToGetAtoms,
|
|
|
|
RULE_NAME as useGetLoadableAndGetValueToGetAtomsName,
|
|
|
|
} from './rules/use-getLoadable-and-getValue-to-get-atoms';
|
2024-03-12 17:12:17 +03:00
|
|
|
import {
|
|
|
|
rule as useRecoilCallbackHasDependencyArray,
|
|
|
|
RULE_NAME as useRecoilCallbackHasDependencyArrayName,
|
|
|
|
} from './rules/useRecoilCallback-has-dependency-array';
|
2024-03-06 02:24:20 +03:00
|
|
|
|
2024-01-04 01:07:25 +03:00
|
|
|
/**
|
|
|
|
* Import your custom workspace rules at the top of this file.
|
|
|
|
*
|
|
|
|
* For example:
|
|
|
|
*
|
|
|
|
* import { RULE_NAME as myCustomRuleName, rule as myCustomRule } from './rules/my-custom-rule';
|
|
|
|
*
|
|
|
|
* In order to quickly get started with writing rules you can use the
|
|
|
|
* following generator command and provide your desired rule name:
|
|
|
|
*
|
|
|
|
* ```sh
|
|
|
|
* npx nx g @nx/eslint:workspace-rule {{ NEW_RULE_NAME }}
|
|
|
|
* ```
|
|
|
|
*/
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
/**
|
|
|
|
* Apply the imported custom rules here.
|
|
|
|
*
|
|
|
|
* For example (using the example import above):
|
|
|
|
*
|
|
|
|
* rules: {
|
|
|
|
* [myCustomRuleName]: myCustomRule
|
|
|
|
* }
|
|
|
|
*/
|
|
|
|
rules: {
|
|
|
|
[componentPropsNamingName]: componentPropsNaming,
|
|
|
|
[effectComponentsName]: effectComponents,
|
|
|
|
[matchingStateVariableName]: matchingStateVariable,
|
|
|
|
[noHardcodedColorsName]: noHardcodedColors,
|
|
|
|
[noStateUserefName]: noStateUseref,
|
|
|
|
[sortCssPropertiesAlphabeticallyName]: sortCssPropertiesAlphabetically,
|
|
|
|
[styledComponentsPrefixedWithStyledName]:
|
|
|
|
styledComponentsPrefixedWithStyled,
|
2024-03-09 12:48:19 +03:00
|
|
|
[explicitBooleanPredicatesInIfName]: explicitBooleanPredicatesInIf,
|
2024-03-06 02:24:20 +03:00
|
|
|
[useGetLoadableAndGetValueToGetAtomsName]:
|
|
|
|
useGetLoadableAndGetValueToGetAtoms,
|
2024-02-25 15:52:48 +03:00
|
|
|
[maxConstsPerFileName]: maxConstsPerFile,
|
2024-03-12 17:12:17 +03:00
|
|
|
[useRecoilCallbackHasDependencyArrayName]:
|
|
|
|
useRecoilCallbackHasDependencyArray,
|
2024-06-04 18:04:57 +03:00
|
|
|
[noNavigatePreferLinkName]: noNavigatePreferLink,
|
2024-07-19 20:17:57 +03:00
|
|
|
[injectWorkspaceRepositoryName]: injectWorkspaceRepository,
|
2024-01-04 01:07:25 +03:00
|
|
|
},
|
|
|
|
};
|