androidOldVersion()
Returns whether the Android version is at or below API 26 so you can perform specific implementations for older versions.
info
Starting with Android API version 26, there were many layout and behavior changes.
Usage
import React from 'react';
import { Text, View } from "react-native";
// React Native UI DevKit
import { androidOldVersion } from 'react-native-ui-devkit';
const App = () => {
return (
<View style={[
androidOldVersion() && {
// your custom style for Android API 26 or below here...
},
{
// your custom style here...
}]}>
<Text>Text</Text>
</View>
);
}
export default App;