mirror of
https://github.com/Choices-js/Choices.git
synced 2024-05-17 13:06:34 +02:00
20 lines
297 B
JavaScript
20 lines
297 B
JavaScript
|
export const defaultState = {
|
||
|
loading: false,
|
||
|
};
|
||
|
|
||
|
const general = (state = defaultState, action) => {
|
||
|
switch (action.type) {
|
||
|
case 'SET_IS_LOADING': {
|
||
|
return {
|
||
|
loading: action.isLoading,
|
||
|
};
|
||
|
}
|
||
|
|
||
|
default: {
|
||
|
return state;
|
||
|
}
|
||
|
}
|
||
|
};
|
||
|
|
||
|
export default general;
|