1- import React from ' react' ;
2- import { Route , useHistory } from ' react-router-dom' ;
3- import { Security , SecureRoute , LoginCallback } from ' @okta/okta-react' ;
4- import Home from ' ./Pages/Home' ;
5- import Game from ' ./Pages/Game'
6- import Login from ' ./Pages/Login'
1+ import React from " react" ;
2+ import { Route , useHistory } from " react-router-dom" ;
3+ import { Security , SecureRoute , LoginCallback } from " @okta/okta-react" ;
4+ import Home from " ./Pages/Home" ;
5+ import Game from " ./Pages/Game" ;
6+ import Login from " ./Pages/Login" ;
77
88const AppWithRouterAccess = ( ) => {
99 const history = useHistory ( ) ;
1010 const onAuthRequired = ( ) => {
11- history . push ( ' /login' ) ;
11+ history . push ( " /login" ) ;
1212 } ;
1313
1414 const baseDomain = process . env . REACT_APP_OKTA_URL_BASE ;
15- const issuer = baseDomain + ' /oauth2/default'
15+ const issuer = baseDomain + " /oauth2/default" ;
1616 const clientId = process . env . REACT_APP_OKTA_CLIENTID ;
17- const redirect = process . env . REACT_APP_OKTA_APP_BASE_URL + ' /implicit/callback' ;
17+ const redirect = process . env . REACT_APP_OKTA_APP_BASE_URL + " /implicit/callback" ;
1818
1919 return (
2020 < Security issuer = { issuer }
@@ -29,4 +29,4 @@ const AppWithRouterAccess = () => {
2929 </ Security >
3030 ) ;
3131} ;
32- export default AppWithRouterAccess ;
32+ export default AppWithRouterAccess ;
0 commit comments