@meadow/redux-api-middleware
Advanced tools
Comparing version 1.0.4 to 1.1.0
@@ -27,2 +27,3 @@ 'use strict'; | ||
var types = definition.types; | ||
var meta = definition.meta; | ||
var promise = definition.promise; | ||
@@ -45,3 +46,4 @@ | ||
dispatch({ | ||
type: REQUEST | ||
type: REQUEST, | ||
meta: meta | ||
}); | ||
@@ -53,3 +55,4 @@ | ||
type: SUCCESS, | ||
payload: data | ||
payload: data, | ||
meta: meta | ||
}); | ||
@@ -64,3 +67,4 @@ }); | ||
payload: err, | ||
error: true | ||
error: true, | ||
meta: meta | ||
}); | ||
@@ -67,0 +71,0 @@ }); |
@@ -17,3 +17,3 @@ 'use strict'; | ||
const { types, promise } = definition; | ||
const { types, meta, promise } = definition; | ||
const [REQUEST, SUCCESS, FAILURE] = types; | ||
@@ -30,3 +30,4 @@ | ||
dispatch({ | ||
type: REQUEST | ||
type: REQUEST, | ||
meta | ||
}); | ||
@@ -37,3 +38,4 @@ | ||
type: SUCCESS, | ||
payload: data | ||
payload: data, | ||
meta | ||
})); | ||
@@ -46,3 +48,4 @@ | ||
payload: err, | ||
error: true | ||
error: true, | ||
meta | ||
})); | ||
@@ -49,0 +52,0 @@ }); |
{ | ||
"name": "@meadow/redux-api-middleware", | ||
"version": "1.0.4", | ||
"version": "1.1.0", | ||
"description": "API middleware for redux", | ||
@@ -5,0 +5,0 @@ "main": "build/middleware.js", |
6278
98