【问题标题】:'Chalet' Family fonts doesn't work in React Native iOS app'Chalet' Family 字体在 React Native iOS 应用程序中不起作用
【发布时间】:2020-02-17 12:02:36
【问题描述】:

我已经习惯了在 react-native 应用中使用 'chalet' 字体。此字体在 'iOS build' 中不起作用,但在 Android 构建中可以正常使用。我尝试过使用其他字体,但它在 iOS 和 android 版本中都可以正常工作。

Can you please check this link for Font-family .ttf files.

如果你们找到任何解决方案,请帮助我!

【问题讨论】:

    标签: react-native fonts react-native-ios custom-font


    【解决方案1】:

    通常 iOS 和 android 的字体名称不同,

    请点击以下链接了解 iOS 字体名称,

    https://medium.com/react-native-training/adding-custom-fonts-to-react-native-b266b41bff7f

    并根据平台名称应用字体

    【讨论】:

    • 这行得通,但是当我们使用 ChaletComprime-CologneEightyChaletComprime-MilanSixty 字体然后 *ChaletComprime-CologneEighty 字体替换在 iOS 中使用 ChaletComprime-MilanSixty 如何解决此问题。
    • 你需要根据平台给出字体名称
    猜你喜欢
    • 2017-02-13
    • 2022-12-29
    • 2021-02-02
    • 2017-06-08
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-08-18
    相关资源
    最近更新 更多