import { reducerWithInitialState } from 'typescript-fsa-reducers' import { IEmbed } from './interfaces' import * as actions from './actions' import { logout } from '../auth/actions' export default reducerWithInitialState({} as IEmbed) .case(actions.fetchEmbedSuccess, (state, embed) => embed) .case(logout, () => ({} as IEmbed))