Moved glitch files to their own location ;)

This commit is contained in:
kibigo!
2017-07-12 01:02:51 -07:00
parent 74eff5456c
commit 297921fce5
33 changed files with 327 additions and 275 deletions

View File

@@ -0,0 +1,20 @@
export const LOCAL_SETTING_CHANGE = 'LOCAL_SETTING_CHANGE';
export function changeLocalSetting(key, value) {
return dispatch => {
dispatch({
type: LOCAL_SETTING_CHANGE,
key,
value,
});
dispatch(saveLocalSettings());
};
};
export function saveLocalSettings() {
return (_, getState) => {
const localSettings = getState().get('local_settings').toJS();
localStorage.setItem('mastodon-settings', JSON.stringify(localSettings));
};
};