Ignite: [RFC] An easy way/script to include fonts

Created on 8 Apr 2016  路  11Comments  路  Source: infinitered/ignite

rnpm can include fonts if they are in an imported package... I'm interested in a way to use that, or other means to include fonts in Android/iOS from an command in the current project.

All 11 comments

That's a great idea.

ignite font add ~/Downloads/comicsans.ttf

For reference, here are how-to articles.
Android: https://medium.com/@gattermeier/custom-fonts-in-react-native-for-android-b8a331a7d2a7#.ii4ol2yee
iOS: https://medium.com/@dabit3/adding-custom-fonts-to-react-native-b266b41bff7f

+1

馃憤

Ya, this would be awesome. I could have used this on every project. Anyone want to tackle this as an Ignite 2 plugin?

+1

+1

+1

Any workaround for this?

I'd love to have help with this.

ignite font --help
ignite font add ~/Downloads/comicsans.ttf
ignite font remove comicsans
ignite font list

That would be a great addition to Ignite.

You'd need to add a command, in the src/commands folder:

  |- commands
      |- font
          |- font.ts
          |- add.ts
          |- remove.ts
          |- list.ts

Something like that.

Hey everyone, I believe this is no longer something Ignite should be concerned about as react-native link will handle any fonts/assets added to the package.json.

  "rnpm": {
    "assets": [
      "./src/theme/fonts/"
    ]
  }
Was this page helpful?
0 / 5 - 0 ratings

Related issues

GantMan picture GantMan  路  3Comments

whalemare picture whalemare  路  3Comments

shawn-tangsc picture shawn-tangsc  路  3Comments

TitanKing picture TitanKing  路  3Comments

tayfunyasar picture tayfunyasar  路  3Comments