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