dynamic_fa_icons

Creator: coderz1093

Last updated:

Add to Cart

Description:

dynamic fa icons

Dynamic FontAwesome icons in Flutter #
Original package to insert FontAwesome icons dynamically in a Flutter app when the icons are not known at compile time.
The version of icons is: 6.5.1

Usage #

Add dynamic_fa_icons and font_awesome_flutter to pubspec.yaml
All icons names must be in the same format you can find
on fontawesome.com (e.g. pizza-slice)

Example #
import 'package:font_awesome_flutter/font_awesome_flutter.dart';
import 'package:dynamic_fa_icons/dynamic_fa_icons.dart';


class MyWidget extends StatelessWidget {
Widget build(BuildContext context) {
return IconButton(
// Use the FaIcon Widget + DynamicFaIcons class for the IconData
icon: FaIcon(DynamicFaIcons.getIconFromName("pizza-slice")),
onPressed: () {
print("Pressed");
}
);
}
}
copied to clipboard
References and attribution #

https://pub.dev/packages/font_awesome_flutter
https://github.com/FortAwesome/Font-Awesome

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Customer Reviews

There are no reviews.