mirror of
https://github.com/shuaiplus/nodewarden.git
synced 2026-06-20 21:00:41 +00:00
Improve app startup and route fallbacks
This commit is contained in:
+9
-4
@@ -15,14 +15,19 @@ const queryClient = new QueryClient({
|
||||
},
|
||||
});
|
||||
|
||||
async function bootstrap(): Promise<void> {
|
||||
await initI18n();
|
||||
const root = document.getElementById('root')!;
|
||||
|
||||
function renderApp(): void {
|
||||
render(
|
||||
<QueryClientProvider client={queryClient}>
|
||||
<App />
|
||||
</QueryClientProvider>,
|
||||
document.getElementById('root')!
|
||||
root
|
||||
);
|
||||
}
|
||||
|
||||
void bootstrap();
|
||||
renderApp();
|
||||
|
||||
void initI18n().then(() => {
|
||||
renderApp();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user