forked from internxt/drive-web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.tsx
55 lines (48 loc) · 1.99 KB
/
index.tsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import App from './App';
import reportWebVitals from './reportWebVitals';
import plugins from './app/core/plugins';
import { store } from './app/store';
import { userActions } from './app/store/slices/user';
import { teamActions } from './app/store/slices/team';
import { planThunks } from './app/store/slices/plan';
import storageThunks from './app/store/slices/storage/storage.thunks';
import { taskManagerThunks } from './app/store/slices/taskManager';
import { sessionActions } from './app/store/slices/session';
import { referralsThunks } from 'app/store/slices/referrals';
import 'react-tooltip/dist/react-tooltip.css';
import './index.scss';
import { SdkFactory } from './app/core/factory/sdk';
import localStorageService from './app/core/services/local-storage.service';
import './app/i18n/services/i18n.service';
import { TranslationProvider } from 'app/i18n/provider/TranslationProvider';
import { HelmetProvider } from 'react-helmet-async';
// Installs plugins
plugins.forEach((plugin) => plugin.install(store));
SdkFactory.initialize(store.dispatch, localStorageService);
// Initializes store
store.dispatch(userActions.initialize());
store.dispatch(teamActions.initialize());
store.dispatch(sessionActions.initialize());
store.dispatch(storageThunks.initializeThunk());
store.dispatch(planThunks.initializeThunk());
store.dispatch(taskManagerThunks.initializeThunk());
store.dispatch(referralsThunks.initializeThunk());
ReactDOM.render(
<React.StrictMode>
<HelmetProvider>
<Provider store={store}>
<TranslationProvider>
<App />
</TranslationProvider>
</Provider>
</HelmetProvider>
</React.StrictMode>,
document.getElementById('root'),
);
// If you want to start measuring performance in your app, pass a function
// to log results (for example: reportWebVitals(console.log))
// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
reportWebVitals();