Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
react-native-redux-router-fixed
Advanced tools
React Native Router using Redux architecture
I've decided to stop supporting this component in favor to new release react-native-router-flux (https://github.com/aksonov/react-native-router-flux). The new version doesn't depend from concrete Flux/Redux implementation and allow you to build nested navigators easily. Also it allows to intercept route 'actions' from your store(s).
'use strict';
var React = require('react-native');
var {AppRegistry, StyleSheet,Text,View} = React;
var Launch = require('./components/Launch');
var Register = require('./components/Register');
var Login = require('./components/Login');
var {Router, routerReducer, Route, Container, Animations, Schema} = require('react-native-redux-router');
var {NavBar, NavBarModal} = require('./components/NavBar');
var Error = require('./components/Error');
var Home = require('./components/Home');
import { createStore, combineReducers } from 'redux';
import { Provider } from 'react-redux/native';
let store = createStore(combineReducers({routerReducer}));
class App extends React.Component {
render(){
return (
<View style={{flex:1}}>
<View style={{position:'absolute',left:0,right:0,top:0,bottom:0,backgroundColor:'#F5FCFF'}}/>
<Router>
<Schema name="modal" sceneConfig={Animations.FlatFloatFromBottom} navBar={NavBarModal}/>
<Schema name="default" sceneConfig={Animations.FlatFloatFromRight} navBar={NavBar}/>
<Schema name="withoutAnimation" navBar={NavBar}/>
<Schema name="tab" navBar={NavBar}/>
<Route name="launch" component={Launch} initial={true} hideNavBar={true} title="Launch"/>
<Route name="register" component={Register} title="Register"/>
<Route name="home" component={Home} title="Home" type="replace"/>
<Route name="login" component={Login} schema="modal"/>
<Route name="register2" component={Register} schema="withoutAnimation"/>
<Route name="error" component={Error} schema="popup"/>
</Router>
</View>
);
}
}
class Example extends React.Component {
render() {
return (
<Provider store={store}>
{() => <App />}
</Provider>
);
}
}
AppRegistry.registerComponent('Example', () => Example);
components/Launch.js (initial screen)
'use strict';
var React = require('react-native');
var {View, Text, StyleSheet, TouchableHighlight} = React;
var Button = require('react-native-button');
var {Actions} = require('react-native-redux-router');
class Launch extends React.Component {
render(){
return (
<View style={styles.container}>
<Text>Launch page</Text>
<Button onPress={()=>Actions.login({data:"Custom data", title:'Custom title' })}>Go to Login page</Button>
<Button onPress={Actions.register}>Go to Register page</Button>
<Button onPress={Actions.register2}>Go to Register page without animation</Button>
<Button onPress={()=>Actions.error("Error message")}>Go to Error page</Button>
</View>
);
}
}
var styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
backgroundColor: 'transparent',
}
});
module.exports = Launch;
npm install react-native-redux-router --save
FAQs
React Native Router using Redux architecture
The npm package react-native-redux-router-fixed receives a total of 0 weekly downloads. As such, react-native-redux-router-fixed popularity was classified as not popular.
We found that react-native-redux-router-fixed 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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.