question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TextInput on working with custom fonts

See original GitHub issue

Hi @nandorojo, love the project – thanks for making this package available.

I’m experiencing issues when using custom fonts specifically when using the dripsy imported TextInput. All my other pages and Text items are using the custom font appropriately.

Have you experienced this or aware of what might be causing it? If I replace the dripsy TextInput with the standard react-native the error goes away.

Thanks!! Ben

AppEntry.bundle?plat…&minify=false:28030 fontFamily "NunitoSans" is not a system font and has not been loaded through Font.loadAsync.

- If you intended to use a system font, make sure you typed the name correctly and that it is supported by your device operating system.

- If this is a custom font, be sure to load it with Font.loadAsync. 

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
benjamin-r-erbcommented, Jan 7, 2021

@nandorojo Thanks again for following up on this. We made the changes you suggested in the loading to set the default weight to the generic font name ‘NunitoSans’ and that got rid of the error that was only appearing for us in the TextInput.

We also took a closer look at the new instructions. The font we are using has many different files for each style/weight, so the arial example with multiple weights per font name caused some confusion.

The other huge realization was that we had an unnecessary theme.text.body style element that was causing our font styling not to work unless using a text variant (which we had adopted as a workaround).

Thankfully everything is working now and we understand the process much better.

Thank you so much for your help and for making this awesome library available!

Best, Ben

0reactions
nandorojocommented, Jan 6, 2021

Any update?

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to apply custom font in textinput field while typing text in ...
Initially typed text using custom font then it became the default font again. How can I resolve it? Font should look like this...
Read more >
Text Input and Custom Fonts (Godot Retro Text Adventure ...
In this tutorial we add a LineEdit node so that we can collect text input from the player in our Zork-like retro text...
Read more >
Applying custom fonts to text | Apple Developer Documentation
To use a custom font, add the font file that contains your licensed font to your app, and then apply the font to...
Read more >
How to Use Google Fonts and Custom Fonts in Jotform
Copy the code inside the style tag. google-fonts-import-code-min.png. Also, take note of the font-family declaration under CSS ...
Read more >
Add a font as an XML resource - Android Developers
Android 8.0 (API level 26) introduces fonts in XML, a feature that lets you use fonts as resources. You can add the font...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found