Skip to content

Commit

Permalink
fix: remove browser router from app
Browse files Browse the repository at this point in the history
  • Loading branch information
SKairinos committed Jul 2, 2023
1 parent 2f8b97c commit 5b92d86
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions src/components/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ import {
Provider,
ProviderProps
} from 'react-redux';
import {
BrowserRouter
} from 'react-router-dom';
import {
Action,
AnyAction
Expand All @@ -29,16 +26,13 @@ import {
ScreenTimeDialog
} from '../features';
import '../scripts';
import ScrollRoutes from './ScrollRoutes';

export interface AppProps<
A extends Action = AnyAction,
S = unknown
> {
theme: ThemeProviderProps['theme'];
store: ProviderProps<A, S>['store'];
header?: React.ReactElement;
footer?: React.ReactElement;
children: React.ReactNode;
maxIdleSeconds?: number;
maxTotalSeconds?: number;
Expand All @@ -50,8 +44,6 @@ const App = <
>({
theme,
store,
header,
footer,
children,
maxIdleSeconds = 60 * 60,
maxTotalSeconds = 60 * 60
Expand Down Expand Up @@ -142,13 +134,7 @@ const App = <
open={!isIdle && tooMuchScreenTime}
onClose={resetTotalSeconds}
/>
<BrowserRouter>
{header}
<ScrollRoutes>
{children}
</ScrollRoutes>
{footer}
</BrowserRouter>
{children}
</Provider>
</ThemeProvider>
);
Expand Down

0 comments on commit 5b92d86

Please sign in to comment.