duplicateCanvasPrefix property

String? get duplicateCanvasPrefix

The prefix this package names twice, or null when each is named once.

Refused rather than resolved, for the reason a duplicate package is: one of the two answers is dropped, and nothing says which — least of all the output, where a rule that lost quietly looks exactly like a rule that never applied.

Implementation

String? get duplicateCanvasPrefix {
  var seen = <String>{};
  for (var canvas in canvases) {
    if (!seen.add(canvas.root)) return canvas.root;
  }
  return null;
}