1
0
mirror of https://github.com/tooot-app/app synced 2025-06-05 22:19:13 +02:00
Files
tooot/src/helpers/getLanguage.ts
xmflsct 0d9992107c Fixed #432
这应该能修复问题1
2022-11-04 23:38:29 +01:00

12 lines
359 B
TypeScript

import { store } from '@root/store'
import { getSettingsLanguage } from '@utils/slices/settingsSlice'
import * as Localization from 'expo-localization'
import { Platform } from "react-native"
const getLanguage = (): string => {
return Platform.OS === 'ios'
? Localization.locale
: getSettingsLanguage(store.getState())
}
export default getLanguage