Skip to content

Version 4.2.1

Compare
Choose a tag to compare
@pburtchaell pburtchaell released this 15 May 15:06

This release adds the default suffix types as module exports, as documented in the Introduction. This is useful for reducers.

import { PENDING, FULFILLED, REJECTED } from 'redux-promise-middleware';

export default function fooReducer(state = {}, action) {
  switch (action.type) {
    case `FOO_${FULFILLED}`:
      return ...
  }
}

Thanks to @piu130 for the PR!