1. Go to https://pub.dev/ to find packages and plug-ins such as flutter_COLOR_plugin
After opening, there are specific installation methods
2, installation,
3, import package: import ‘package: flutter_COLOR_plugin/flutter_COLOR_plugin. dart’;
4, the use of
body: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
Text(
'You have pushed the button this many times:',
style: TextStyle(color: ColorUtil.color('# 899900')),
),
Text(
'$_counter',
style: Theme.of(context).textTheme.display1,
),
],
),
),
Copy the code
5. Effect: Changed the font color