flutter_extensions 0.2.5 copy "flutter_extensions: ^0.2.5" to clipboard
flutter_extensions: ^0.2.5 copied to clipboard

outdated

A new Flutter project.

flutter_extensions #

Adds several extensions

Dart #

Color #

Extensions color code we thank "TinyColor"

Iterable

Command Description
tryFirstWhereType return a first element where type is T else null
more more

String #

Command Description
ifEmpty if string is empty returns a 'text' otherwise return string
isBlank if string is empty or contains only space returns true otherwise returns false
ifBlank(() => 'text') if string is empty or contains only space returns 'text' otherwise returns string

Widgets #

Listenable - ChangeNotifier

Widget Description
ChangeableProvider ...
ChangeableBuilder listen to a Listenable and construct the ui based on the changes
ChangeableListener ...
ChangeableConsumer to do...
ChangeableValueBuilder listen to a Listenable and construct the ui based on the changes only if they respect the 'condition' or the value does not change
ChangeableValueListener to do...
ChangeableValueConsumer to do...

Others

Widget Description
SizeCopier Update a SizeCopierController with the size of the child
SizeCopy Create a SizedWidget taking inspiration from SizeCopierController