Custom lintsprefer_lastOn this pageprefer_lastWarns about usage of iterable[length - 1] or iterable.elementAt(length - 1) instead of iterable.last. Example BAD: final a = [1, 2, 3];a[a.length - 1]; // LINTa.elementAt(a.length - 1); // LINT GOOD: final a = [1, 2, 3];a.last; // OK