I18nManager.forceRTL doesn't applies changes in first app load

后端 未结 5 1804
一生所求
一生所求 2021-02-18 21:37

I have an app that created by awesome React-native and my layout designed to be in RTL mode. I\'ve set up an option for forcing the layout to be RT

5条回答
  •  我寻月下人不归
    2021-02-18 22:24

    Thats because you should use I18nManager with try and catch! it needs "await" to do his job.

    try {
        I18nManager.allowRTL(false);
      } catch (e) {
        console.log(e);
      }
    

    use it like this, and it will work.

提交回复
热议问题