![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
react-native-simple-tablayout
Advanced tools
A tablayout or tab navigation in which you can customize its tabs property and its indicator by passing appropriate props
npm i react-native-simple-tablayout
import React from 'react';
import {View,Text, Dimensions, SafeAreaView} from 'react-native';
import TabLayout from 'react-native-simple-tablayout';
const {width}=Dimensions.get('window');
const Screen1=(props)=>{
return (
<View style={{flex : 1,alignItems:'center',width,backgroundColor:props.color,justifyContent:'center'}}>
<Text>{props.text}</Text>
</View>
)
}
const Screen2=(props)=>{
return (
<View style={{flex : 1,alignItems:'center',width,backgroundColor:props.color,justifyContent:'center'}}>
<Text>{props.text}</Text>
</View>
)
}
const Screen3=(props)=>{
return (
<View style={{flex : 1,alignItems:'center',width,backgroundColor:props.color,justifyContent:'center'}}>
<Text>{props.text}</Text>
</View>
)
}
//(Recommendations )
// Make screens components seperately and use React.memo for better performance.
const App=()=>{
// tab name passed as array of string
const tabName=["Home","Trending","Account"]
//tab screen passed as array of screens
const data=[
<Screen1 text="Home" color="#ffb338"/>,
<Screen2 text="Trending" color="#e307b7"/>,
<Screen3 text="Account" color="#3ae307"/>,
];
return (
<SafeAreaView style={{flex : 1}}>
<TabLayout
screens={data}
tabName={tabName}
indicatorHeight={3}
indicatorRadius={5}
titleFontSize={18}
titleColor="white"
tabHeight={50}
/>
</SafeAreaView>
)
}
export default App;
Props | Types |
---|---|
screens | Array of screens (screens must passed as jsx i.e ) |
tabName | Array of string i.e ['home','profile','trending'] |
tabHeight (optional) | Integer |
indicatorColor (optional) | color i.e either hex value , rgb , rgba |
indicatorHeight (optional) | Integer |
indicatorRadius (optional) | Integer |
indicatorColor (optional) | color i.e either hex value , rgb , rgba |
tabPressedColor (optional) | color i.e either hex value , rgb , rgba (just after clicking the tab) |
tabColor (optional) | color i.e either hex value , rgb , rgba (background color of tab) |
titleFontSize (optional) | Integer |
titleFontWeight (optional) | string i.e "normal" or "italic" or "bold" |
titleColor (optional) | color i.e either hex value , rgb , rgba |
titleFontFamilyAndroid (optional) | string (any font family for android) |
titleFontFamilyIos (optional) | string (any font family for ios) |
titleFontStyle (optional) | string (any font style) |
FAQs
A tablayout or tab navigation in which you can customize its tabs property and its indicator by passing appropriate props
The npm package react-native-simple-tablayout receives a total of 4 weekly downloads. As such, react-native-simple-tablayout popularity was classified as not popular.
We found that react-native-simple-tablayout demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.