-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Open
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listc: proposalA detailed proposal for a change to FlutterA detailed proposal for a change to Flutterframeworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.team-frameworkOwned by Framework teamOwned by Framework teamtriaged-frameworkTriaged by Framework teamTriaged by Framework team
Description
Discussion here: #103833
[BoxShape.oval] There is a comment saying new shapes shouldn't go here.
I should probably have included more information in the comment saying why:
Each new enum value is a lot of new code in a bunch of places, including in code we don't control (e.g. app code, that's why the Google tests are failing), so we'd need to write a migration guide and migrate a bunch of code.
- Each new enum value requires new code in a bunch of places.
- That new code likely won't get tree-shaken out, since I don't think the compiler can know which values are never used. So this has a permanent binary size cost even for people who don't use it.
- In principle, we've moved to ShapeBorders rather than BoxShape for new shapes, and the existence of BoxShape is just a legacy feature at this point. Adding more shapes encourages people to use BoxShape in the future.
So I think it is worth trying to remove it. We can't deprecate BoxShape completely because InkWell uses it. But we can remove from BoxDecoration.
Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listc: proposalA detailed proposal for a change to FlutterA detailed proposal for a change to Flutterframeworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.team-frameworkOwned by Framework teamOwned by Framework teamtriaged-frameworkTriaged by Framework teamTriaged by Framework team