npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

react-native-navigation-redux

v0.0.16

Published

Missing Redux feature for awesome Wix React Native Navigation V2

Readme

react-native-navigation-redux

Missing Redux feature for awesome Wix React Native Navigation V2

The main goal of this package is to make it possible to navigate outside of React Component, for instance from within sagas.

Like this:

function* handleSomeCoolAction(action: someCoolAction) {
  yield put(push({
    component: {
      name: 'screens.SomeCoolScreen',
    },
  }))
}

export default [
  takeLatest(ActionTypes.SOME_COOL_ACTION, handleSomeCoolAction),
];

Installation

Yarn

yarn add react-native-navigation-redux

NPM

npm install react-native-navigation-redux

HOC (RNNR)

In your main index.js file:

import { RNNR } from 'react-native-navigation-redux'
new RNNR(new App(), store);

Sometimes you might want to exclude some components from being exposed as currently visible, for instance custom Top Bar Components, as obviously there is no way to navigate within such components.

To do that, simply pass an array of component names (registered screens) that you want to exclude:

const excludedComponents = ['TopBarComponent'];

new RNNR(new App(), store, excludedComponents);

Connect Reducer

In your reducers builder file:

import { navigation } from 'react-native-navigation-redux'

Connect Saga

In your saga builder file:

import { navigationSaga } from 'react-native-navigation-redux'

Usage

this.props.dispatch(push({
  component: {
    name: 'screens.Welcome',
  },
}))

You can also write your own saga functions to handle navigation actions:

const getComponentId = state => state.navigation.componentId;

function* handlePush(action: push) {
  const componentId = yield select(getComponentId);
  yield Navigation.push(componentId, action.layout);
  // Or do what you ever want to do on navigation PUSH action.
}

export default [
  takeLatest(ActionTypes.PUSH, handlePush),
];

Switch active tab programmatically

Assuming that you have defined your BottomTabsId as described in the RNN documentation

const bottomTabs = {
     id: 'BottomTabsId', <--- here
     children: [...

All you need to switch tab using this library is simply dispatch switchTabToIndex action

dispatch(switchTabToIndex('BottomTabsId', 2));