diff --git a/CHANGELOG.md b/CHANGELOG.md index e40edde5e..33b4eb4f4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ This change log adheres to standards from [Keep a CHANGELOG](https://keepachange ### Changed - [Docs] [`no-relative-packages`]: fix typo ([#3066], thanks [@joshuaobrien]) - [Performance] [`no-cycle`]: dont scc for each linted file ([#3068], thanks [@soryy708]) +- [Docs] [`no-cycle`]: add `disableScc` to docs ([#3070], thanks [@soryy708]) ## [2.30.0] - 2024-09-02 @@ -1141,6 +1142,7 @@ for info on changes for earlier releases. [`memo-parser`]: ./memo-parser/README.md +[#3070]: https://github.com/import-js/eslint-plugin-import/pull/3070 [#3068]: https://github.com/import-js/eslint-plugin-import/pull/3068 [#3066]: https://github.com/import-js/eslint-plugin-import/pull/3066 [#3065]: https://github.com/import-js/eslint-plugin-import/pull/3065 diff --git a/docs/rules/no-cycle.md b/docs/rules/no-cycle.md index 76e96f95f..898b75330 100644 --- a/docs/rules/no-cycle.md +++ b/docs/rules/no-cycle.md @@ -94,6 +94,14 @@ export function getBar() { return import('./bar'); } > Cyclic dependency are **always** a dangerous anti-pattern as discussed extensively in [#2265](https://github.com/import-js/eslint-plugin-import/issues/2265). Please be extra careful about using this option. +#### `disableScc` + +This option disables a pre-processing step that calculates [Strongly Connected Components](https://en.wikipedia.org/wiki/Strongly_connected_component), which are used for avoiding unnecessary work checking files in different SCCs for cycles. + +However, under some configurations, this pre-processing may be more expensive than the time it saves. + +When this option is `true`, we don't calculate any SCC graph, and check all files for cycles (leading to higher time-complexity). Default is `false`. + ## When Not To Use It This rule is comparatively computationally expensive. If you are pressed for lint