Skip to content

Commit

Permalink
Inline actionType
Browse files Browse the repository at this point in the history
It seems to get compiled away when building for react-native
  • Loading branch information
felixSchl authored and ethul committed Aug 28, 2017
1 parent 2aa5438 commit a4b25b6
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/React/Redux.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@ var Redux = require('redux');

var ReactRedux = require('react-redux');

var actionType = '@@PURESCRIPT_REACT_REDUX';

function startsWithActionType(actionForeign) {
var index = actionForeign.type.indexOf(actionType);
var index = actionForeign.type.indexOf('@@PURESCRIPT_REACT_REDUX');

return index === 0;
}
Expand All @@ -16,7 +14,7 @@ function makeActionForeign(action) {
var constructorName = action.constructor && action.constructor.name ? action.constructor.name : 'UnknownConstructorName';

var actionForeign = {
type: actionType + '/' + constructorName,
type: '@@PURESCRIPT_REACT_REDUX/' + constructorName,
action: action
};

Expand Down

0 comments on commit a4b25b6

Please # to comment.