accounts-frontend/packages/app/components/ui/bsod/dispatchBsod.js

21 lines
448 B
JavaScript
Raw Normal View History

2016-07-30 00:59:27 +05:30
import React from 'react';
import ReactDOM from 'react-dom';
import { bsod } from './actions';
import BSoD from 'app/components/ui/bsod/BSoD';
2016-07-30 00:59:27 +05:30
let injectedStore;
let onBsod;
export default function dispatchBsod(store = injectedStore) {
store.dispatch(bsod());
onBsod && onBsod();
2016-07-30 00:59:27 +05:30
2019-12-07 16:58:52 +05:30
ReactDOM.render(<BSoD />, document.getElementById('app'));
2016-07-30 00:59:27 +05:30
}
export function inject(store, stopLoading) {
injectedStore = store;
onBsod = stopLoading;
2016-07-30 00:59:27 +05:30
}