redux-map-actions

1.0.0 • Public • Published

Redux-map-actions

Simple action namespacer for redux actions.

Installation

npm install redux-map-actions

Usage

import { mapActions } from 'redux-map-actions';

const actionTypes = mapActions([
  'LOAD_USERS',
  'LOGIN_USER',
  'UPDATE_USER'
], 'USERS');

// the value of actionTypes will be
{
  LOAD_USERS: "USERS/LOAD_USERS",
  LOGIN_USER: "USERS/LOGIN_USER",
  UPDATE_USER: "USERS/UPDATE_USER",
}

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i redux-map-actions

      Weekly Downloads

      1

      Version

      1.0.0

      License

      ISC

      Last publish

      Collaborators

      • coverslide