目錄
目錄

Do use sound null safety.

This rule has been removed as of the latest Dart releases.

Details

DO use sound null safety, by not specifying a dart version lower than 2.12.

BAD:

// @dart=2.8
a() {
}

GOOD:

b() {
}

Usage

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

linter:
  rules:
    - enable_null_safety