1.0.5 • Published 4 years ago

react-native-split-pane v1.0.5

Weekly downloads
1
License
MIT
Repository
github
Last release
4 years ago

react-native-split-pane

Split pane

Install

npm i react-native-split-pane or yarn add react-native-split-pane

It depends on react-native-app-interface, so should execute pod install after install script

Shortcuts

open

Usage

import SplitPane from 'react-native-split-pane';

export default () => {
	function onChange(value) {
		console.log('onChange', value);
	}
	
	return (
		<SplitPane style={styles.container}
    		           separatorStyle={styles.separator}
    		           split="h"
    		           primary='first'
    		           defaultValue={100}
    		           min={50}
    		           max={300}
    		           onChange={onChange}
    		>
    			<View><Text>A</Text></View>
    			<View><Text>B</Text></View>
    		</SplitPane>
	);
}

Props

proptyperequireddefault
split'h' or 'v'false'h'
primary'first' or 'second'false'first'
childrenreact-nodestrue
styleanyfalse
separatorStyleanyfalse
separatorWidthnumberfalse2
defaultValuenumberfalse
valuenumberfalse
onChange(value)=>voidfalse
minnumberfalse0
maxnumberfalse