You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
MeteoMaxEtPaul/redux/reducers/VilleRechercheReducer.ts

12 lines
279 B

const initialState = {
villes: [],
}
export default villeRechercheReducer = (state = initialState, action) => {
switch (action.type) {
case FETCH_VILLES:
return {...state, villes: state.villes.push(action.payload)};
default:
return state;
}
}