mirror of
https://github.com/reduxjs/redux-devtools.git
synced 2025-07-26 07:59:48 +03:00
Add type
This commit is contained in:
parent
f19e1fd1cb
commit
0915714127
|
@ -9,6 +9,7 @@ import configureStore from '../../../app/stores/windowStore';
|
||||||
import getPreloadedState from '../background/getPreloadedState';
|
import getPreloadedState from '../background/getPreloadedState';
|
||||||
|
|
||||||
import '../../views/window.pug';
|
import '../../views/window.pug';
|
||||||
|
import { MonitorMessage } from '../../../app/middlewares/api';
|
||||||
|
|
||||||
const position = location.hash;
|
const position = location.hash;
|
||||||
let preloadedState: PreloadedState<StoreState>;
|
let preloadedState: PreloadedState<StoreState>;
|
||||||
|
@ -24,7 +25,7 @@ chrome.runtime.getBackgroundPage((window) => {
|
||||||
name += chrome.devtools.inspectedWindow.tabId;
|
name += chrome.devtools.inspectedWindow.tabId;
|
||||||
}
|
}
|
||||||
const bg = chrome.runtime.connect({ name });
|
const bg = chrome.runtime.connect({ name });
|
||||||
const update = (action) => {
|
const update = (action?: MonitorMessage) => {
|
||||||
localStore.dispatch(action || { type: UPDATE_STATE });
|
localStore.dispatch(action || { type: UPDATE_STATE });
|
||||||
};
|
};
|
||||||
bg.onMessage.addListener(update);
|
bg.onMessage.addListener(update);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user