https://kotlinlang.org logo
#detekt
Title
# detekt
k

kenkyee

05/16/2020, 12:04 PM
What do folks do with LongParameterList warnings? I used to recommend that people use a data class to pass paramaters into a constructor or function to group the parameters logically. The current versions of Detekt also flag too many parameters in data class constructors... 😔
j

Jukka Siivonen

05/16/2020, 2:14 PM
There's a parameter for that which should be true by default ignoreDataClasses https://arturbosch.github.io/detekt/complexity.html
👍 1
j

John Towell

05/18/2020, 6:33 PM
we ignored it and wrote our own to warn only for long
unnamed
parameters, similar to this suggestion https://github.com/detekt/detekt/issues/1007
long named parameters is more readable than long unnamed parameters to a data object imo
149 Views