prefer_collection_literals

Group: style

Maturity: stable

Dart SDK: >= 2.0.0 • (Linter v0.1.30)

View the Project on GitHub dart-lang/linter

DO use collection literals when possible.

BAD:

var points = new List();
var addresses = new Map();
var uniqueNames = new Set();

GOOD:

var points = [];
var addresses = <String,String>{};
var uniqueNames = <String>{};