How to use the @okta/okta-react.Auth function in @okta/okta-react

To help you get started, we’ve selected a few @okta/okta-react examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github mabc224 / node-okta-react-redux / client / src / index.js View on Github external
import { createStore, applyMiddleware, compose } from 'redux';
import { Provider } from 'react-redux';
import logger from 'redux-logger';
import thunk from 'redux-thunk';
import { createBrowserHistory } from 'history';
const history = createBrowserHistory();

/* eslint-disable no-underscore-dangle */
const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose;
const store = createStore(
    reducers, composeEnhancers(applyMiddleware(logger, thunk))
);
/* eslint-enable */

const auth = new Auth({
    history,
    issuer: config.issuer,
    client_id: config.client_id,
    redirect_uri: config.redirect_uri,
    onAuthRequired: ({history}) => history.push('/node-okta-react-redux/login')
});

ReactDOM.render(
    
        
            
                
            
        
    ,
    document.getElementById('root')
github transmute-industries / transmute / packages / transmute-dashboard / src / components / Routes / index.js View on Github external
import MetaMask from '../MetaMask';
import Register from '../Auth/Register';
import ProfilePage from '../Profile';
import RecoveryPage from '../Profile/RecoveryPage';
import DirectoryPage from '../DirectoryPage';
import DirectoryProfilePage from '../DirectoryPage/DirectoryProfilePage';
import MessagesPage from '../Messages';
import GroupsPage from '../Groups/GroupsPage';
import GroupPage from '../Groups/GroupPage';
import EventStoreFactoryPage from '../EventStoreFactoryPage';
import EventStorePage from '../EventStorePage';
import StreamModelPage from '../StreamModelPage';

import { ToastContainer } from 'react-toastify';

const auth = new Auth({
  issuer: config.issuer,
  client_id: config.client_id,
  redirect_uri: config.redirect_uri,
  history
});

class Routes extends React.Component {
  render() {
    return (

@okta/okta-react

React support for Okta

Apache-2.0
Latest version published 5 months ago

Package Health Score

75 / 100
Full package analysis

Popular @okta/okta-react functions