/** * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import { Linter } from 'eslint'; import ExhaustiveDeps from './ExhaustiveDeps'; import { name, version } from './package.json'; import RulesOfHooks from './RulesOfHooks'; export const __EXPERIMENTAL__ = false; export const flatConfigs = { recommended: { name: 'react-hooks/recommended', plugins: { 'react-hooks': { meta: { name, version }, rules: { 'rules-of-hooks': RulesOfHooks, 'exhaustive-deps': ExhaustiveDeps, }, }, }, rules: { 'react-hooks/rules-of-hooks': 'error', 'react-hooks/exhaustive-deps': 'warn', }, } satisfies Linter.Config, };