store input keys in content script

This commit is contained in:
Shin'ya Ueoka 2017-10-07 18:38:57 +09:00
parent a6b197ca73
commit 8ff302a1f2
7 changed files with 92 additions and 119 deletions

View file

@ -1,7 +1,6 @@
import * as settingsActions from 'actions/setting';
import messages from 'content/messages';
import BackgroundComponent from 'components/background';
import BackgroundInputComponent from 'components/background-input';
import reducers from 'reducers';
import { createStore } from 'store';
@ -15,10 +14,8 @@ const store = createStore(reducers, (e, sender) => {
}
});
const backgroundComponent = new BackgroundComponent(store);
const backgroundInputComponent = new BackgroundInputComponent(store);
store.subscribe((sender) => {
backgroundComponent.update(sender);
backgroundInputComponent.update(sender);
});
store.dispatch(settingsActions.load());