Last updated:
0 purchases
heroicons flutter
heroicons_flutter #
Heroicons from
Tailwind Labs as Flutter icons set. See the
demo here.
Icons List #
All the available icons can be found at the
official Heroicons website or at the
demo site built with this package.
Usage #
All the available Heroicons can be used as Flutter icon as shown below.
import 'package:heroicons_flutter/heroicons_flutter.dart';
class MyWidget extends StatelessWidget {
const MyWidget({super.key});
Widget build(BuildContext context) {
return new Column(
children: <Widget>[
const Icon(
// Solid Icon
HeroiconsSolid.faceSmile,
color: Colors.blue,
),
const Icon(
// Mini Icon
HeroiconsMini.banknotes,
color: Colors.blue,
),
Icon(
// Outline Icon
HeroiconsOutline.academicCap,
color: Colors.blue,
)
Icon(
// Micro Icon
HeroiconsOutline.radio,
color: Colors.blue,
)
],
);
}
}
copied to clipboard
You can also use the icon by passing the string icon names to the fromString()
method as below.
[!WARNING] Tree shaking won’t work when fromString() is used since this
needs to go through the list of icons to find the one that matches the given
string.
// camelCase
HericonsOutline.fromString("academicCap")
copied to clipboard
fromString() method also accepts snake_case, kebab-case and dot.notation
strings.
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.