flutter_vector_icons 0.1.0

flutter_vector_icons #

pub

Flutter version of react-native-vector-icons

Bundled Icon Sets #

Browse all.

  • AntDesign by AntFinance (297 icons)
  • Entypo by Daniel Bruce (411 icons)
  • EvilIcons by Alexander Madyankin & Roman Shamin (v1.10.1, 70 icons)
  • Feather by Cole Bemis & Contributors (v4.7.0, 266 icons)
  • FontAwesome by Dave Gandy (v4.7.0, 675 icons)
  • Foundation by ZURB, Inc. (v3.0, 283 icons)
  • Ionicons by Ben Sperry (v4.2.4, 696 icons)

Installation #

Add flutter_vector_icons as a dependency in your pubspec.yaml file

Usage #

import 'package:flutter/material.dart';
import 'package:flutter_vector_icons/flutter_vector_icons.dart';

class MyWidget extends StatelessWidget {
  Widget build(BuildContext context) {
    return IconButton(
      // Variable name is the same as font name:
      //
      // AntDesign
      // Entypo
      // EvilIcons
      // Feather
      // FontAwesome
      // Foundation
      // Ionicons
      // MaterialCommunityIcons
      // Octicons
      // SimpleLineIcons
      // Zocial

      icon: Icon(MaterialCommunityIcons.star),

      onPressed: () {
        print('Star it');
      },
    );
  }
}

Development #

  1. Copy font files to fonts directory
  2. Copy glyphmaps json files to glyphmaps directory
  3. run dart tool/generate.dart

Credits #

License #

MIT

0.0.1 #

  • Initial version

0.0.2 #

  • Add missing fontPackage option

0.1.0 #

  • Add examples and Changelog following maintenance issues and suggestions

example/flutter_vector_icons_example.dart

import 'package:flutter/material.dart';
import 'package:flutter_vector_icons/flutter_vector_icons.dart';

class MyWidget extends StatelessWidget {
  Widget build(BuildContext context) {
    return IconButton(
      // Variable name is the same as font name:
      //
      // AntDesign
      // Entypo
      // EvilIcons
      // Feather
      // FontAwesome
      // Foundation
      // Ionicons
      // MaterialCommunityIcons
      // Octicons
      // SimpleLineIcons
      // Zocial

      icon: Icon(MaterialCommunityIcons.star),
      onPressed: () {
        print('Star it');
      },
    );
  }
}

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  flutter_vector_icons: ^0.1.0

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:flutter_vector_icons/flutter_vector_icons.dart';
  
Version Uploaded Documentation Archive
0.1.0 Mar 6, 2019 Go to the documentation of flutter_vector_icons 0.1.0 Download flutter_vector_icons 0.1.0 archive
0.0.2 Feb 15, 2019 Go to the documentation of flutter_vector_icons 0.0.2 Download flutter_vector_icons 0.0.2 archive
0.0.1 Feb 15, 2019 Go to the documentation of flutter_vector_icons 0.0.1 Download flutter_vector_icons 0.0.1 archive
Popularity:
Describes how popular the package is relative to other packages. [more]
88
Health:
Code health derived from static analysis. [more]
99
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
100
Overall:
Weighted score of the above. [more]
94
Learn more about scoring.

We analyzed this package on Jun 26, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.3.2
  • pana: 0.12.19
  • Flutter: 1.5.4-hotfix.2

Platforms

Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Health issues and suggestions

Document public APIs. (-1 points)

6800 out of 6800 API elements have no dartdoc comment.Providing good documentation for libraries, classes, functions, and other API elements improves code readability and helps developers find and use your API.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0 <3.0.0
flutter 0.0.0
Transitive dependencies
collection 1.14.11
meta 1.1.6 1.1.7
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
dart_style ^1.2.3
flutter_test