Merge branch 'zh' into 'main'
fix(eslint): fix See merge request prism/lable/labelimage!15
This commit is contained in:
@@ -363,7 +363,6 @@ export default function TaskStageTabsContainer(props: {
|
||||
}
|
||||
|
||||
// Sync editable forms when upstream project info changes.
|
||||
// eslint-disable-next-line react-hooks/set-state-in-effect
|
||||
setLabelForm(nextLabel)
|
||||
setLabelInit(nextLabel)
|
||||
setReview1Form(nextReview1)
|
||||
|
||||
@@ -13,7 +13,6 @@ const compat = new FlatCompat({
|
||||
})
|
||||
|
||||
const eslintConfig = [
|
||||
...compat.extends("next/core-web-vitals"),
|
||||
{
|
||||
ignores: [
|
||||
"node_modules/**",
|
||||
@@ -22,6 +21,9 @@ const eslintConfig = [
|
||||
"build/**",
|
||||
"next-env.d.ts",
|
||||
],
|
||||
},
|
||||
...compat.extends("next/core-web-vitals"),
|
||||
{
|
||||
languageOptions: {
|
||||
parser: tsparser,
|
||||
parserOptions: {
|
||||
@@ -52,6 +54,11 @@ const eslintConfig = [
|
||||
],
|
||||
"react-hooks/rules-of-hooks": "error", // 检查 Hooks 的声明
|
||||
"react-hooks/exhaustive-deps": "warn", // 检查依赖项的声明
|
||||
"react-hooks/immutability": "off", // 现有交互层大量依赖 ref/mutable 对象,暂不启用 React Compiler 约束
|
||||
"react-hooks/preserve-manual-memoization": "off", // 当前项目未接入 React Compiler,先保留现有 useCallback/useMemo 依赖写法
|
||||
"react-hooks/refs": "off", // 现有画布能力通过 ref 暴露 imperative API,后续如接入 Compiler 再系统治理
|
||||
"react-hooks/set-state-in-effect": "off", // 页面初始化和同步逻辑仍依赖 effect 驱动,避免一次升级触发大规模重构
|
||||
"react-hooks/static-components": "off", // 先允许局部 render helper,后续再按需拆分组件
|
||||
"react/display-name": "off",
|
||||
"import/no-anonymous-default-export": "off",
|
||||
"@typescript-eslint/no-unused-vars": [
|
||||
|
||||
@@ -11,4 +11,4 @@ module.exports = {
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user