Redux function:
function setAllVideos(state, action) {
return tassign(state, { allVideos: state.allVideos.join([action.data]) });}
Declaration + State:
allVideos: Array<Object>;
AND
allVideos: [],
I just can't seem to get the syntax right on joining these together.
Correct should be
return tassign(state, { allVideos: state.allVideos.concat(action.data) });