Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

chore: drop slow lint rules (#31205)

Stephen Zhoub3902374ac6d
diff --git a/web/eslint-suppressions.json b/web/eslint-suppressions.json
index 86b7095f2bd..125e94ece90 100644
--- a/web/eslint-suppressions.json
+++ b/web/eslint-suppressions.json
@@ -81,11 +81,6 @@
"count": 1
}
},
- "app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/range-selector.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/__tests__/svg-attribute-error-reproduction.spec.tsx": {
"no-console": {
"count": 19
@@ -95,9 +90,6 @@
}
},
"app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-panel.tsx": {
- "react-hooks/static-components": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -132,11 +124,6 @@
"count": 1
}
},
- "app/account/(commonLayout)/delete-account/components/feed-back.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/account/(commonLayout)/delete-account/components/verify-email.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
@@ -253,9 +240,6 @@
}
},
"app/components/app/app-publisher/features-wrapper.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 19
- },
"ts/no-explicit-any": {
"count": 4
}
@@ -283,11 +267,6 @@
"count": 1
}
},
- "app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.tsx": {
- "react-hooks/use-memo": {
- "count": 1
- }
- },
"app/components/app/configuration/config-prompt/simple-prompt-input.tsx": {
"ts/no-explicit-any": {
"count": 3
@@ -322,9 +301,6 @@
}
},
"app/components/app/configuration/config/agent/agent-tools/index.spec.tsx": {
- "react-hooks/globals": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 5
}
@@ -375,11 +351,6 @@
"count": 1
}
},
- "app/components/app/configuration/config/automatic/version-selector.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/app/configuration/config/code-generator/get-code-generator-res.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 4
@@ -418,11 +389,6 @@
"count": 1
}
},
- "app/components/app/configuration/dataset-config/params-config/config-content.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/app/configuration/dataset-config/params-config/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
@@ -485,9 +451,6 @@
}
},
"app/components/app/configuration/debug/hooks.tsx": {
- "react-hooks/refs": {
- "count": 7
- },
"ts/no-explicit-any": {
"count": 3
}
@@ -568,9 +531,6 @@
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 6
},
- "react-hooks/refs": {
- "count": 2
- },
"style/multiline-ternary": {
"count": 2
},
@@ -779,9 +739,6 @@
}
},
"app/components/base/chat/chat-with-history/chat-wrapper.tsx": {
- "react-hooks/refs": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 6
}
@@ -864,9 +821,6 @@
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 2
},
- "react-hooks/refs": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 15
}
@@ -890,9 +844,6 @@
}
},
"app/components/base/chat/embedded-chatbot/chat-wrapper.tsx": {
- "react-hooks/refs": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 6
}
@@ -906,9 +857,6 @@
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 6
},
- "react-hooks/refs": {
- "count": 5
- },
"ts/no-explicit-any": {
"count": 16
}
@@ -957,17 +905,11 @@
"app/components/base/date-and-time-picker/date-picker/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 4
- },
- "react-hooks/refs": {
- "count": 5
}
},
"app/components/base/date-and-time-picker/time-picker/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 2
- },
- "react-hooks/preserve-manual-memoization": {
- "count": 3
}
},
"app/components/base/dialog/index.stories.tsx": {
@@ -985,11 +927,6 @@
"count": 2
}
},
- "app/components/base/features/context.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/base/features/new-feature-panel/annotation-reply/index.tsx": {
"ts/no-explicit-any": {
"count": 3
@@ -1005,11 +942,6 @@
"count": 2
}
},
- "app/components/base/features/new-feature-panel/conversation-opener/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/base/features/new-feature-panel/conversation-opener/modal.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
@@ -1026,9 +958,6 @@
}
},
"app/components/base/features/new-feature-panel/moderation/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -1059,18 +988,10 @@
}
},
"app/components/base/file-uploader/hooks.ts": {
- "react-hooks/use-memo": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 3
}
},
- "app/components/base/file-uploader/store.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/base/file-uploader/utils.spec.ts": {
"test/no-identical-title": {
"count": 1
@@ -1085,17 +1006,11 @@
}
},
"app/components/base/form/components/base/base-field.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 3
}
},
"app/components/base/form/components/base/base-form.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 6
}
@@ -1159,9 +1074,6 @@
}
},
"app/components/base/form/hooks/use-get-validators.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 3
}
@@ -1251,9 +1163,6 @@
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 10
},
- "react-hooks/refs": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 9
}
@@ -1336,9 +1245,6 @@
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 7
},
- "react-hooks/purity": {
- "count": 1
- },
"regexp/no-super-linear-backtracking": {
"count": 3
},
@@ -1406,15 +1312,9 @@
"app/components/base/notion-page-selector/page-selector/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
- },
- "react-hooks/immutability": {
- "count": 1
}
},
"app/components/base/pagination/index.tsx": {
- "react-hooks/refs": {
- "count": 2
- },
"unicorn/prefer-number-properties": {
"count": 1
}
@@ -1430,12 +1330,6 @@
}
},
"app/components/base/portal-to-follow-elem/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- },
- "react-hooks/refs": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -1453,11 +1347,6 @@
"count": 2
}
},
- "app/components/base/prompt-editor/plugins/component-picker-block/hooks.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- }
- },
"app/components/base/prompt-editor/plugins/component-picker-block/index.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -1489,9 +1378,6 @@
}
},
"app/components/base/prompt-editor/plugins/workflow-variable-block/workflow-variable-block-replacement-block.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -1534,11 +1420,6 @@
"count": 1
}
},
- "app/components/base/search-input/index.tsx": {
- "react-hooks/refs": {
- "count": 1
- }
- },
"app/components/base/select/index.stories.tsx": {
"no-console": {
"count": 4
@@ -1558,11 +1439,6 @@
"count": 1
}
},
- "app/components/base/select/pure.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- }
- },
"app/components/base/slider/index.stories.tsx": {
"no-console": {
"count": 2
@@ -1629,18 +1505,10 @@
"no-console": {
"count": 2
},
- "react-hooks/purity": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
},
- "app/components/base/voice-input/index.tsx": {
- "react-hooks/immutability": {
- "count": 1
- }
- },
"app/components/base/voice-input/utils.ts": {
"ts/no-explicit-any": {
"count": 4
@@ -1716,11 +1584,6 @@
"count": 1
}
},
- "app/components/datasets/common/document-status-with-action/auto-disabled-document.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 5
- }
- },
"app/components/datasets/common/image-previewer/index.tsx": {
"no-irregular-whitespace": {
"count": 1
@@ -1731,11 +1594,6 @@
"count": 3
}
},
- "app/components/datasets/common/image-uploader/store.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/datasets/common/image-uploader/utils.ts": {
"ts/no-explicit-any": {
"count": 2
@@ -1746,20 +1604,12 @@
"count": 1
}
},
- "app/components/datasets/common/retrieval-param-config/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/datasets/create/file-preview/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
}
},
"app/components/datasets/create/file-uploader/index.tsx": {
- "react-hooks/immutability": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 3
}
@@ -1873,9 +1723,6 @@
"app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
- },
- "react-hooks/immutability": {
- "count": 1
}
},
"app/components/datasets/documents/create-from-pipeline/data-source/online-drive/connect/index.spec.tsx": {
@@ -1908,11 +1755,6 @@
"count": 2
}
},
- "app/components/datasets/documents/create-from-pipeline/data-source/store/provider.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/datasets/documents/create-from-pipeline/data-source/store/slices/online-drive.ts": {
"ts/no-explicit-any": {
"count": 4
@@ -1953,21 +1795,11 @@
"count": 1
}
},
- "app/components/datasets/documents/detail/completed/child-segment-list.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- }
- },
"app/components/datasets/documents/detail/completed/common/chunk-content.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
}
},
- "app/components/datasets/documents/detail/completed/common/regeneration-modal.tsx": {
- "react-hooks/purity": {
- "count": 1
- }
- },
"app/components/datasets/documents/detail/completed/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 6
@@ -1977,9 +1809,6 @@
}
},
"app/components/datasets/documents/detail/completed/new-child-segment.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -1989,14 +1818,6 @@
"count": 1
}
},
- "app/components/datasets/documents/detail/embedding/index.tsx": {
- "react-hooks/immutability": {
- "count": 1
- },
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- }
- },
"app/components/datasets/documents/detail/index.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -2011,22 +1832,11 @@
}
},
"app/components/datasets/documents/detail/new-segment.tsx": {
- "react-hooks/purity": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
},
- "app/components/datasets/documents/detail/settings/document-settings.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/datasets/documents/detail/settings/pipeline-settings/index.tsx": {
- "react-hooks/refs": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 6
}
@@ -2061,21 +1871,6 @@
"count": 1
}
},
- "app/components/datasets/extra-info/service-api/card.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
- "app/components/datasets/formatted-text/flavours/edit-slice.tsx": {
- "react-hooks/refs": {
- "count": 1
- }
- },
- "app/components/datasets/formatted-text/flavours/preview-slice.tsx": {
- "react-hooks/refs": {
- "count": 1
- }
- },
"app/components/datasets/formatted-text/flavours/type.ts": {
"ts/no-empty-object-type": {
"count": 1
@@ -2086,21 +1881,11 @@
"count": 1
}
},
- "app/components/datasets/hit-testing/index.tsx": {
- "react-hooks/purity": {
- "count": 1
- }
- },
"app/components/datasets/list/dataset-card/hooks/use-dataset-card-state.ts": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
}
},
- "app/components/datasets/metadata/base/date-picker.tsx": {
- "react-hooks/purity": {
- "count": 1
- }
- },
"app/components/datasets/metadata/edit-metadata-batch/input-combined.tsx": {
"ts/no-explicit-any": {
"count": 2
@@ -2126,11 +1911,6 @@
"count": 1
}
},
- "app/components/datasets/metadata/metadata-dataset/dataset-metadata-drawer.tsx": {
- "react-hooks/static-components": {
- "count": 1
- }
- },
"app/components/datasets/settings/form/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 2
@@ -2234,15 +2014,9 @@
"app/components/goto-anything/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
- },
- "react-hooks/preserve-manual-memoization": {
- "count": 9
}
},
"app/components/header/account-setting/data-source-page-new/card.tsx": {
- "react-hooks/immutability": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 2
}
@@ -2262,20 +2036,12 @@
"count": 1
}
},
- "app/components/header/account-setting/data-source-page-new/operator.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/header/account-setting/data-source-page-new/types.ts": {
"ts/no-explicit-any": {
"count": 2
}
},
"app/components/header/account-setting/data-source-page/data-source-website/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -2298,9 +2064,6 @@
"app/components/header/account-setting/members-page/invite-modal/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 3
- },
- "react-hooks/preserve-manual-memoization": {
- "count": 3
}
},
"app/components/header/account-setting/members-page/transfer-ownership-modal/index.tsx": {
@@ -2367,9 +2130,6 @@
}
},
"app/components/header/account-setting/model-provider-page/model-modal/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 5
}
@@ -2392,18 +2152,9 @@
"app/components/header/account-setting/model-provider-page/provider-added-card/cooldown-timer.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 2
- },
- "react-hooks/immutability": {
- "count": 1
- },
- "react-hooks/purity": {
- "count": 1
}
},
"app/components/header/account-setting/model-provider-page/provider-added-card/credential-panel.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -2444,21 +2195,11 @@
"count": 1
}
},
- "app/components/header/dataset-nav/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 6
- }
- },
"app/components/header/header-wrapper.tsx": {
"ts/no-explicit-any": {
"count": 1
}
},
- "app/components/header/nav/nav-selector/index.tsx": {
- "react-hooks/use-memo": {
- "count": 1
- }
- },
"app/components/plugins/install-plugin/hooks.ts": {
"ts/no-explicit-any": {
"count": 4
@@ -2477,11 +2218,6 @@
"count": 2
}
},
- "app/components/plugins/install-plugin/install-bundle/steps/install.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/plugins/install-plugin/install-from-github/index.tsx": {
"ts/no-explicit-any": {
"count": 3
@@ -2585,11 +2321,6 @@
"count": 1
}
},
- "app/components/plugins/plugin-detail-panel/detail-header.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/plugins/plugin-detail-panel/endpoint-card.tsx": {
"ts/no-explicit-any": {
"count": 2
@@ -2638,24 +2369,11 @@
"count": 2
}
},
- "app/components/plugins/plugin-detail-panel/subscription-list/create/common-modal.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/plugins/plugin-detail-panel/subscription-list/create/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
},
- "app/components/plugins/plugin-detail-panel/subscription-list/create/oauth-client.tsx": {
- "react-hooks/immutability": {
- "count": 1
- }
- },
"app/components/plugins/plugin-detail-panel/subscription-list/delete-confirm.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -2786,11 +2504,6 @@
"count": 1
}
},
- "app/components/rag-pipeline/components/panel/input-field/field-list/hooks.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 3
- }
- },
"app/components/rag-pipeline/components/panel/input-field/field-list/index.spec.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -2801,16 +2514,6 @@
"count": 1
}
},
- "app/components/rag-pipeline/components/panel/input-field/index.tsx": {
- "react-hooks/refs": {
- "count": 3
- }
- },
- "app/components/rag-pipeline/components/panel/test-run/header.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/index.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -2866,16 +2569,6 @@
"count": 1
}
},
- "app/components/rag-pipeline/hooks/use-available-nodes-meta-data.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
- "app/components/rag-pipeline/hooks/use-configs-map.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/rag-pipeline/hooks/use-input-fields.ts": {
"ts/no-explicit-any": {
"count": 2
@@ -2892,26 +2585,15 @@
}
},
"app/components/rag-pipeline/hooks/use-pipeline-init.ts": {
- "react-hooks/immutability": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 2
}
},
"app/components/rag-pipeline/hooks/use-pipeline-run.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 1
}
},
- "app/components/rag-pipeline/hooks/use-pipeline-start-run.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/rag-pipeline/index.spec.tsx": {
"ts/no-explicit-any": {
"count": 8
@@ -2953,11 +2635,6 @@
"count": 3
}
},
- "app/components/share/text-generation/run-batch/csv-download/index.spec.tsx": {
- "react-hooks/globals": {
- "count": 1
- }
- },
"app/components/share/text-generation/run-batch/csv-reader/index.spec.tsx": {
"ts/no-explicit-any": {
"count": 2
@@ -2968,15 +2645,7 @@
"count": 2
}
},
- "app/components/share/text-generation/run-batch/res-download/index.spec.tsx": {
- "react-hooks/globals": {
- "count": 1
- }
- },
"app/components/share/text-generation/run-once/index.spec.tsx": {
- "react-hooks/globals": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 4
}
@@ -3022,11 +2691,6 @@
"count": 3
}
},
- "app/components/tools/mcp/detail/operation-dropdown.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/tools/mcp/mcp-server-modal.tsx": {
"ts/no-explicit-any": {
"count": 5
@@ -3060,11 +2724,6 @@
"count": 1
}
},
- "app/components/tools/provider/custom-create-card.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/tools/provider/empty.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -3085,11 +2744,6 @@
"count": 15
}
},
- "app/components/tools/workflow-tool/configure-button.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- }
- },
"app/components/tools/workflow-tool/index.tsx": {
"ts/no-explicit-any": {
"count": 2
@@ -3103,11 +2757,6 @@
"count": 3
}
},
- "app/components/workflow-app/components/workflow-header/features-trigger.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow-app/components/workflow-main.tsx": {
"ts/no-explicit-any": {
"count": 2
@@ -3128,20 +2777,12 @@
"count": 1
}
},
- "app/components/workflow-app/hooks/use-configs-map.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow-app/hooks/use-nodes-sync-draft.ts": {
"ts/no-explicit-any": {
"count": 2
}
},
"app/components/workflow-app/hooks/use-workflow-init.ts": {
- "react-hooks/immutability": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 3
}
@@ -3152,9 +2793,6 @@
}
},
"app/components/workflow-app/hooks/use-workflow-run.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 13
}
@@ -3175,9 +2813,6 @@
}
},
"app/components/workflow/__tests__/trigger-status-sync.test.tsx": {
- "react-hooks/use-memo": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 2
}
@@ -3187,11 +2822,6 @@
"count": 1
}
},
- "app/components/workflow/block-selector/data-sources.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/workflow/block-selector/featured-tools.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 2
@@ -3231,9 +2861,6 @@
"app/components/workflow/block-selector/tool/tool.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 2
- },
- "react-hooks/preserve-manual-memoization": {
- "count": 4
}
},
"app/components/workflow/block-selector/trigger-plugin/action-item.tsx": {
@@ -3259,21 +2886,6 @@
"count": 2
}
},
- "app/components/workflow/context.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
- "app/components/workflow/datasets-detail-store/provider.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
- "app/components/workflow/header/header-in-normal.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/header/run-mode.tsx": {
"no-console": {
"count": 1
@@ -3287,11 +2899,6 @@
"count": 1
}
},
- "app/components/workflow/hooks-store/provider.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/workflow/hooks-store/store.ts": {
"ts/no-explicit-any": {
"count": 6
@@ -3326,9 +2933,6 @@
}
},
"app/components/workflow/hooks/use-nodes-interactions.ts": {
- "react-hooks/immutability": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 8
}
@@ -3440,9 +3044,6 @@
}
},
"app/components/workflow/nodes/_base/components/input-var-type-icon.tsx": {
- "react-hooks/static-components": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -3462,11 +3063,6 @@
"count": 1
}
},
- "app/components/workflow/nodes/_base/components/next-step/add.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- }
- },
"app/components/workflow/nodes/_base/components/node-handle.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
@@ -3492,31 +3088,16 @@
"count": 1
}
},
- "app/components/workflow/nodes/_base/components/toggle-expand-btn.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/nodes/_base/components/variable/match-schema-type.ts": {
"ts/no-explicit-any": {
"count": 8
}
},
- "app/components/workflow/nodes/_base/components/variable/output-var-list.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/nodes/_base/components/variable/utils.ts": {
"ts/no-explicit-any": {
"count": 32
}
},
- "app/components/workflow/nodes/_base/components/variable/var-list.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/nodes/_base/components/variable/var-reference-picker.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 2
@@ -3525,23 +3106,10 @@
"count": 3
}
},
- "app/components/workflow/nodes/_base/components/variable/variable-label/base/variable-icon.tsx": {
- "react-hooks/static-components": {
- "count": 1
- }
- },
- "app/components/workflow/nodes/_base/components/variable/variable-label/hooks.ts": {
- "react-hooks/use-memo": {
- "count": 2
- }
- },
"app/components/workflow/nodes/_base/components/workflow-panel/index.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 3
},
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 6
}
@@ -3558,9 +3126,6 @@
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
},
- "react-hooks/preserve-manual-memoization": {
- "count": 3
- },
"ts/no-explicit-any": {
"count": 7
}
@@ -3586,9 +3151,6 @@
"app/components/workflow/nodes/_base/hooks/use-toggle-expend.ts": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
- },
- "react-hooks/refs": {
- "count": 2
}
},
"app/components/workflow/nodes/_base/hooks/use-var-list.ts": {
@@ -3698,18 +3260,10 @@
}
},
"app/components/workflow/nodes/data-source-empty/hooks.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 3
- },
"ts/no-explicit-any": {
"count": 1
}
},
- "app/components/workflow/nodes/data-source-empty/index.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/nodes/data-source/default.ts": {
"ts/no-explicit-any": {
"count": 5
@@ -3796,11 +3350,6 @@
"count": 1
}
},
- "app/components/workflow/nodes/if-else/components/condition-list/condition-item.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/nodes/if-else/default.ts": {
"ts/no-explicit-any": {
"count": 1
@@ -3811,11 +3360,6 @@
"count": 5
}
},
- "app/components/workflow/nodes/index.tsx": {
- "react-hooks/static-components": {
- "count": 1
- }
- },
"app/components/workflow/nodes/iteration/default.ts": {
"ts/no-explicit-any": {
"count": 1
@@ -3826,11 +3370,6 @@
"count": 1
}
},
- "app/components/workflow/nodes/iteration/use-interactions.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/nodes/iteration/use-single-run-form-params.ts": {
"ts/no-explicit-any": {
"count": 6
@@ -3882,9 +3421,6 @@
}
},
"app/components/workflow/nodes/knowledge-retrieval/use-single-run-form-params.ts": {
- "react-hooks/refs": {
- "count": 3
- },
"ts/no-explicit-any": {
"count": 5
}
@@ -3915,9 +3451,6 @@
}
},
"app/components/workflow/nodes/llm/components/json-schema-config-modal/code-editor.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 4
}
@@ -3937,11 +3470,6 @@
"count": 2
}
},
- "app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/context.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/auto-width-input.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
@@ -3971,9 +3499,6 @@
}
},
"app/components/workflow/nodes/llm/use-single-run-form-params.ts": {
- "react-hooks/refs": {
- "count": 3
- },
"ts/no-explicit-any": {
"count": 9
}
@@ -3994,9 +3519,6 @@
}
},
"app/components/workflow/nodes/loop/components/loop-variables/item.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 3
- },
"ts/no-explicit-any": {
"count": 4
}
@@ -4040,9 +3562,6 @@
}
},
"app/components/workflow/nodes/parameter-extractor/use-single-run-form-params.ts": {
- "react-hooks/refs": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 9
}
@@ -4071,27 +3590,16 @@
}
},
"app/components/workflow/nodes/question-classifier/use-single-run-form-params.ts": {
- "react-hooks/refs": {
- "count": 2
- },
"ts/no-explicit-any": {
"count": 8
}
},
- "app/components/workflow/nodes/start/components/var-list.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/nodes/start/panel.tsx": {
"ts/no-explicit-any": {
"count": 2
}
},
"app/components/workflow/nodes/start/use-config.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 1
}
@@ -4257,22 +3765,9 @@
"count": 5
}
},
- "app/components/workflow/note-node/index.tsx": {
- "react-hooks/refs": {
- "count": 1
- }
- },
- "app/components/workflow/note-node/note-editor/context.tsx": {
- "react-hooks/refs": {
- "count": 2
- }
- },
"app/components/workflow/note-node/note-editor/plugins/link-editor-plugin/component.tsx": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
- },
- "react-hooks/refs": {
- "count": 1
}
},
"app/components/workflow/note-node/note-editor/utils.ts": {
@@ -4347,9 +3842,6 @@
}
},
"app/components/workflow/panel/debug-and-preview/hooks.ts": {
- "react-hooks/purity": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 7
}
@@ -4362,24 +3854,11 @@
"count": 1
}
},
- "app/components/workflow/panel/index.tsx": {
- "react-hooks/use-memo": {
- "count": 1
- }
- },
"app/components/workflow/panel/inputs-panel.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 4
}
},
- "app/components/workflow/panel/version-history-panel/context-menu/use-context-menu.ts": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/components/workflow/panel/version-history-panel/index.spec.tsx": {
"ts/no-explicit-any": {
"count": 2
@@ -4513,9 +3992,6 @@
}
},
"app/components/workflow/update-dsl-modal.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 2
}
@@ -4581,9 +4057,6 @@
}
},
"app/components/workflow/variable-inspect/right.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- },
"ts/no-explicit-any": {
"count": 3
}
@@ -4617,11 +4090,6 @@
"count": 1
}
},
- "app/components/workflow/workflow-preview/components/note-node/index.tsx": {
- "react-hooks/refs": {
- "count": 1
- }
- },
"app/education-apply/hooks.ts": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 5
@@ -4662,11 +4130,6 @@
"count": 1
}
},
- "app/signin/invite-settings/page.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 1
- }
- },
"app/signin/layout.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -4682,11 +4145,6 @@
"count": 1
}
},
- "app/signup/set-password/page.tsx": {
- "react-hooks/preserve-manual-memoization": {
- "count": 2
- }
- },
"context/app-context.tsx": {
"ts/no-explicit-any": {
"count": 1
@@ -4738,9 +4196,6 @@
"hooks/use-moderate.ts": {
"react-hooks-extra/no-direct-set-state-in-use-effect": {
"count": 1
- },
- "react-hooks/refs": {
- "count": 1
}
},
"hooks/use-oauth.ts": {
diff --git a/web/eslint.config.mjs b/web/eslint.config.mjs
index 05c75026122..12f32c5dce4 100644
--- a/web/eslint.config.mjs
+++ b/web/eslint.config.mjs
@@ -9,7 +9,9 @@ import difyI18n from './eslint-rules/index.js'
export default antfu(
{
react: {
- reactCompiler: true,
+ // This react compiler rules are pretty slow
+ // We can wait for https://github.com/Rel1cx/eslint-react/issues/1237
+ reactCompiler: false,
overrides: {
'react/no-context-provider': 'off',
'react/no-forward-ref': 'off',
@@ -57,47 +59,8 @@ export default antfu(
// sonar
{
rules: {
- ...sonar.configs.recommended.rules,
- // code complexity
- 'sonarjs/cognitive-complexity': 'off',
- 'sonarjs/no-nested-functions': 'warn',
- 'sonarjs/no-nested-conditional': 'warn',
- 'sonarjs/nested-control-flow': 'warn', // 3 levels of nesting
- 'sonarjs/no-small-switch': 'off',
- 'sonarjs/no-nested-template-literals': 'warn',
- 'sonarjs/redundant-type-aliases': 'off',
- 'sonarjs/regex-complexity': 'warn',
- // maintainability
- 'sonarjs/no-ignored-exceptions': 'off',
- 'sonarjs/no-commented-code': 'warn',
- 'sonarjs/no-unused-vars': 'warn',
- 'sonarjs/prefer-single-boolean-return': 'warn',
- 'sonarjs/duplicates-in-character-class': 'off',
- 'sonarjs/single-char-in-character-classes': 'off',
- 'sonarjs/anchor-precedence': 'warn',
- 'sonarjs/updated-loop-counter': 'off',
- 'sonarjs/no-dead-store': 'error',
- 'sonarjs/no-duplicated-branches': 'warn',
- 'sonarjs/max-lines': 'warn', // max 1000 lines
- 'sonarjs/no-variable-usage-before-declaration': 'error',
- // security
-
- 'sonarjs/no-hardcoded-passwords': 'off', // detect the wrong code that is not password.
- 'sonarjs/no-hardcoded-secrets': 'off',
- 'sonarjs/pseudo-random': 'off',
- // performance
- 'sonarjs/slow-regex': 'warn',
- // others
- 'sonarjs/todo-tag': 'warn',
- 'sonarjs/table-header': 'off',
-
- // new from this update
- 'sonarjs/unused-import': 'off',
- 'sonarjs/use-type-alias': 'warn',
- 'sonarjs/single-character-alternation': 'warn',
- 'sonarjs/no-os-command-from-path': 'warn',
- 'sonarjs/class-name': 'off',
- 'sonarjs/no-redundant-jump': 'warn',
+ // Manually pick rules that are actually useful and not slow.
+ // Or we can just drop the plugin entirely.
},
plugins: {
sonarjs: sonar,