Closed
Description
Use case
I believe new developers has benefitted from the readability of the 'out of the box' colour parameter in container. Therefore, I am proposing the same with the commonly used Text widget.
Colour changes in Container widget has been introduced as follows:
Container(color: Colors.red)
// Instead of
Container(decoration: BoxDecoration(color: Colors.red));
Is the reason for container out of the box colour parameter better readability and ease of understanding for new Flutter developers? Otherwise, what's the reason?
However, text widget has no colour parameter out of the box. To change a colour, you have to type an additional object.
Text('example', style: TextStyle(color: Colors.red));
Proposal
Have the text widget to have a colour and fontSize parameters without using TextStyle. These two parameters I believe is the most used parameters in the Text widget.
// Before
Text('example', style: TextStyle(color: Colors.red, fontSize: 30));
// After
Text('example', color: Colors.red, fontSize: 30);