InvokeAI/invokeai/frontend/src/main.tsx
Lincoln Stein 9ad4c03277 Various fixes
1) Downgrade numpy to avoid dependency conflict with numba
2) Move all non ldm/invoke files into `invokeai`. This includes assets, backend, frontend, and configs.
3) Fix up way that the backend finds the frontend and the generator finds the NSFW caution.png icon.
2023-01-30 18:42:17 -05:00

40 lines
1.1 KiB
TypeScript

import React from 'react';
import ReactDOM from 'react-dom/client';
import { ChakraProvider } from '@chakra-ui/react';
import { CacheProvider } from '@emotion/react';
import createCache from '@emotion/cache';
import { store } from './app/store';
import { Provider } from 'react-redux';
import { PersistGate } from 'redux-persist/integration/react';
import { persistor } from './persistor';
import Loading from './Loading';
import App from './app/App';
export const emotionCache = createCache({
key: 'invokeai-style-cache',
prepend: true,
});
// Custom Styling
import './styles/index.scss';
// Localization
import './i18n';
ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
<React.StrictMode>
<Provider store={store}>
<PersistGate loading={<Loading />} persistor={persistor}>
<CacheProvider value={emotionCache}>
<ChakraProvider>
<React.Suspense fallback={<Loading />}>
<App />
</React.Suspense>
</ChakraProvider>
</CacheProvider>
</PersistGate>
</Provider>
</React.StrictMode>
);