Add the package and font to the app.

Use the font.

Note:
  Check out the google_fonts package for direct access
  to almost 1000 open-sourced font families.

1. Add a font to a package

To export a font from a package, you need to import the font files into the
lib folder of the package project. You can place font files directly in the
lib folder or in a subdirectory, such as lib/fonts.

In this example, assume you’ve got a Flutter library called
awesome_package with fonts living in a lib/fonts folder.

2. Add the package and fonts to the app

Now you can use the fonts in the package by
updating the pubspec.yaml in the app’s root directory.

Add the package to the app

dependencies

awesome_package

<latest_version>

Declare the font assets