Quantcast
Channel: Active questions tagged react-native+android - Stack Overflow
Viewing all articles
Browse latest Browse all 28480

who to have rtl support in React Native in some pages and components and not affect the whole app?

$
0
0

I am working on an App and set the allow rtl to false

 sharedI18nUtilInstance.allowRTL(getApplicationContext(), false);

now I have a material ui text field that needs to be rtl in some pages but when I set i18manager force rtl in ComponentDidMount it forces the whole app to have rtl I just need it in some pages

  componentDidMount() {
    if (!I18nManager.isRTL) {
      I18nManager.forceRTL(true);
    }
  }

note: the textfield direction rtl does work


Viewing all articles
Browse latest Browse all 28480

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>