max_lines_for_function

SeverityQuick FixOptions
Info

Details

A function should not exceed a certain number of lines.

Usage

To enable the max_lines_for_function rule, add max_lines_for_function under custom_lint > rules in your analysis_options.yaml file:

custom_lint:
  rules:
    - max_lines_for_function

Options

OptionTypeDescriptionDefault Value
max_linesintThe maximum number of lines.100

To configure the maximum number of lines, add an int to the max_lines option:

custom_lint:
  rules:
    - max_lines_for_function:
      max_lines: 200