shlink-web-client/src/index.js

32 lines
983 B
JavaScript
Raw Normal View History

2018-06-03 21:12:40 +03:00
import 'bootstrap/dist/css/bootstrap.min.css';
2018-05-13 09:57:47 +03:00
import React from 'react';
import { render } from 'react-dom';
2018-06-03 21:12:40 +03:00
import { Provider } from 'react-redux';
2018-06-03 14:15:52 +03:00
import { BrowserRouter } from 'react-router-dom';
import { homepage } from '../package.json';
2018-05-13 09:57:47 +03:00
import registerServiceWorker from './registerServiceWorker';
import container from './container';
import store from './container/store';
import { fixLeafletIcons } from './utils/utils';
import 'react-datepicker/dist/react-datepicker.css';
import 'leaflet/dist/leaflet.css';
import './common/react-tagsinput.scss';
import './index.scss';
2018-05-13 09:57:47 +03:00
// This overwrites icons used for leaflet maps, fixing some issues caused by webpack while processing the CSS
fixLeafletIcons();
const { App, ScrollToTop } = container;
2018-06-03 21:12:40 +03:00
render(
2018-06-03 21:12:40 +03:00
<Provider store={store}>
<BrowserRouter basename={homepage}>
2018-08-05 12:20:09 +03:00
<ScrollToTop>
<App />
</ScrollToTop>
2018-06-03 21:12:40 +03:00
</BrowserRouter>
</Provider>,
2018-06-03 14:15:52 +03:00
document.getElementById('root')
);
2018-05-13 09:57:47 +03:00
registerServiceWorker();