2017-10-28 10:55:27 +03:00
|
|
|
import React from 'react';
|
|
|
|
import ReactDOM from 'react-dom';
|
|
|
|
import './index.css';
|
|
|
|
import App from './App';
|
2017-12-02 01:54:41 +03:00
|
|
|
import Splashscreen from './components/misc/Splashscreen'
|
2017-11-28 04:16:41 +03:00
|
|
|
import registerServiceWorker from './registerServiceWorker';
|
2017-11-24 06:05:02 +03:00
|
|
|
|
2017-12-02 01:54:41 +03:00
|
|
|
function Detect(props) {
|
|
|
|
const metamask = props.metamask;
|
|
|
|
if(typeof metamask === 'undefined') {
|
|
|
|
return <Splashscreen />
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
return <App />
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-11-24 06:05:02 +03:00
|
|
|
ReactDOM.render(
|
2017-12-02 01:54:41 +03:00
|
|
|
<Detect metamask={window.web3} />, document.getElementById('root')
|
2017-11-24 06:05:02 +03:00
|
|
|
);
|
2017-11-28 04:16:41 +03:00
|
|
|
registerServiceWorker();
|