yahoi
Version:
Yet Another Highly Opinionated Isomorphic Framework
22 lines (17 loc) • 684 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
exports.default = ExampleReducer;
function ExampleReducer() {
var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
var action = arguments[1];
var type = action.type,
payload = action.payload;
switch (type) {
case 'UPDATE_STORE':
return _extends({}, state, payload);
}
return state;
}