You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the LongParameterList rule applies to all constructors but has an opt-out for data classes. I'd like to suggest adding a new configuration to ignore based on annotations, such as javax.inject.Inject. This comes up often in our DI plumbing
The text was updated successfully, but these errors were encountered:
Please go ahead. I think this a good idea.
Do you have resources to tackle this? @ZacSweers
It should be very easy to add this in the LongParameterList class in the following function.
The function can be extended to check constructor.annotations.any { ignoreAnnotated.contains(it.text) }.
Resolvesdetekt#2563
This adds a new `ignoreAnnotated` option to `LongParameterList`, that allows for ignoring annotations within function/class/file scope.
* Add ignoreAnnotated option to LongParameterList
Resolves#2563
This adds a new `ignoreAnnotated` option to `LongParameterList`, that allows for ignoring annotations within function/class/file scope.
* Fix detekt issues
* Fix docs
* Fix moar
* Add inject
* Use deprecated instead
* Consolidate KAnnotated
* Use function
Co-Authored-By: M Schalk <30376729+schalkms@users.noreply.github.com>
* Fix suggestion conflicts
* Fix detekt
Co-authored-by: M Schalk <30376729+schalkms@users.noreply.github.com>
Expected Behavior of the rule
Context
Currently the
LongParameterList
rule applies to all constructors but has an opt-out for data classes. I'd like to suggest adding a new configuration to ignore based on annotations, such asjavax.inject.Inject
. This comes up often in our DI plumbingThe text was updated successfully, but these errors were encountered: