mirror of
https://github.com/apache/superset.git
synced 2024-09-12 00:29:39 -04:00
fix: QueryParamProvider error on backend rendered views (#23567)
This commit is contained in:
parent
08375ca31a
commit
61e71bb455
@ -20,15 +20,16 @@
|
||||
// Menu App. Used in views that do not already include the Menu component in the layout.
|
||||
// eg, backend rendered views
|
||||
import React from 'react';
|
||||
import { Provider } from 'react-redux';
|
||||
import ReactDOM from 'react-dom';
|
||||
import { Route, BrowserRouter } from 'react-router-dom';
|
||||
import { CacheProvider } from '@emotion/react';
|
||||
import { QueryParamProvider } from 'use-query-params';
|
||||
import createCache from '@emotion/cache';
|
||||
import { ThemeProvider } from '@superset-ui/core';
|
||||
import Menu from 'src/views/components/Menu';
|
||||
import { theme } from 'src/preamble';
|
||||
import getBootstrapData from 'src/utils/getBootstrapData';
|
||||
|
||||
import { Provider } from 'react-redux';
|
||||
import { setupStore } from './store';
|
||||
|
||||
// Disable connecting to redux debugger so that the React app injected
|
||||
@ -46,7 +47,14 @@ const app = (
|
||||
<CacheProvider value={emotionCache}>
|
||||
<ThemeProvider theme={theme}>
|
||||
<Provider store={store}>
|
||||
<BrowserRouter>
|
||||
<QueryParamProvider
|
||||
ReactRouterRoute={Route}
|
||||
stringifyOptions={{ encode: false }}
|
||||
>
|
||||
<Menu data={menu} />
|
||||
</QueryParamProvider>
|
||||
</BrowserRouter>
|
||||
</Provider>
|
||||
</ThemeProvider>
|
||||
</CacheProvider>
|
||||
|
Loading…
Reference in New Issue
Block a user