Home > other >  I wanted to add this font to assets
I wanted to add this font to assets

Time:01-24

enter image description here

assets:
   - assets/
       
   fonts:
     - family: Schyler
       fonts:
        - asset: fonts/Schyler-Regular.ttf
        - asset: fonts/Schyler-Italic.ttf
  
    - family: Trajan Pro
      fonts:
        - asset: fonts/TrajanPro.ttf
        - asset: fonts/TrajanPro_Bold.ttf
         weight: 700

I wanted to add this font to assets

CodePudding user response:

your indentation is not correct pubspec.yaml is giving error when you have wrong indentation in it give a tab space before

fonts:

check out this screen shot and make the indentation like this enter image description here

CodePudding user response:

It's more likely that the indentation of the whole block is wrong (or missing).

Read the following enter image description here

Check more about adding assets-and-images.

  • Related