Comparing version 0.7.0 to 0.7.1
@@ -81,8 +81,4 @@ /* fluxury - Copyright 2015 Peter Moresi */ | ||
var reducers = Object.freeze(reducer) | ||
console.log('foo') | ||
reducer = ((state, action) => { | ||
console.log( action, methods ) | ||
if (action && typeof action.type === 'string' && reducers.hasOwnProperty(action.type)) { | ||
console.log('foo2') | ||
return reducers[action.type](state, action); | ||
@@ -104,2 +100,5 @@ } | ||
addListener: function(cb) { | ||
if (typeof cb !== 'function') { | ||
throw "Callback must be a function"; | ||
} | ||
return emitter.addListener(changedEvent, cb) | ||
@@ -106,0 +105,0 @@ }, |
@@ -90,8 +90,4 @@ /* fluxury - Copyright 2015 Peter Moresi */ | ||
var reducers = Object.freeze(reducer); | ||
console.log('foo'); | ||
reducer = function (state, action) { | ||
console.log(action, methods); | ||
if (action && typeof action.type === 'string' && reducers.hasOwnProperty(action.type)) { | ||
console.log('foo2'); | ||
return reducers[action.type](state, action); | ||
@@ -113,2 +109,5 @@ } | ||
addListener: function addListener(cb) { | ||
if (typeof cb !== 'function') { | ||
throw "Callback must be a function"; | ||
} | ||
return emitter.addListener(changedEvent, cb); | ||
@@ -115,0 +114,0 @@ }, |
{ | ||
"name": "fluxury", | ||
"version": "0.7.0", | ||
"version": "0.7.1", | ||
"description": "Add luxury sugar to simplify implementing Facebook's flavor of Flux architecture.", | ||
@@ -20,3 +20,4 @@ "main": "./lib/index.js", | ||
"immutable": "^3.7.5", | ||
"tape": "^4.2.2" | ||
"tape": "^4.2.2", | ||
"webpack": "^1.12.9" | ||
}, | ||
@@ -23,0 +24,0 @@ "repository": { |
@@ -77,5 +77,2 @@ # fluxury | ||
}) | ||
// To trigger an increment action use: | ||
// dispatch('INC') or dispatch({ type: 'INC' }) | ||
``` | ||
@@ -82,0 +79,0 @@ |
20453
4
195