https://kotlinlang.org logo
#ktlint
Title
# ktlint
y

Yurii Gromyk

09/28/2023, 9:29 AM
Hi everyone! As the disableRules.set method has been deprecated, how should I go about disabling some of the rules now? I couldn't find a clear explanation in either the documentation or on GitHub. Could someone clarify? I understand that rules can now be disabled using either .editorconfig or ktlint.yml. Which method is preferred?
w

wakingrufus

09/28/2023, 12:27 PM
Are you referring to disableRules.set in ktlint-gradle? if so, yes, and I recommend .editorconfig as a replacement
❤️ 1
p

Paul Dingemans

09/28/2023, 12:57 PM
Yes,
.editorconfig
is preferred. And here you can find ktlint documentation where it documented how to disable rules: https://pinterest.github.io/ktlint/1.0.0/faq/#how-do-i-enable-or-disable-a-rule
6 Views