Skip to content

Sniff to discourage "long" closures #192

@jrfnl

Description

@jrfnl

Closures are generally intended for small code snippets.

A sniff could be written to check that a closure is limited to # lines / code line (excluding inline docs) / statements and throw an error suggesting using a named function instead.

The number of lines and whether it should look for lines / code lines / statements could be made configurable.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions