Skip to content

About

React.js starter project demonstrating OIDC authentication using create-react-app and oidc-client.

Resources

Stars

1 star

Watchers

3 watching

Forks

Latest commit

 

History

3 Commits

Folders and files

Repository files navigation

PlusAuth React Starter Project

Simple React project demonstrates basic authentication flows with PlusAuth

Explore the PlusAuth React docs »

Table of Contents
  • About The Project
  • Prerequisites
  • Getting Started
  • License
  • What is PlusAuth

  • About The Project

    It is a simple React project demonstrating basic authentication flows such as register, login, and logout. To keep things simple, we bootstrapped the project with create-react-app and used @plusauth/plusauth-oidc-client-js for authentication.

    Prerequisites

    Before running the project, you must first follow these steps:

    1. Create a PlusAuth account and a tenant at PlusAuth Dashboard
    2. Navigate to the Clients tab and create a client of type Single Page Application
    3. Go to the details page of the client that you've just created and set the following fields as:
    • Redirect Uris: http://localhost:3000/callback, http://localhost:3000/silent-renew.html
    • Post-Logout Redirect Uris: http://localhost:3000

    Please note your Client Id that will be required in the application's configuration.

    Getting Started

    First, we need to supply the required configuration values for the application. Rename .env.example file as .env.

    Then configure the .env file using your Client Id and your PlusAuth tenant name.

    Finally, start the server:

    npm start
    # or with yarn
    yarn start

    The example is hosted at http://localhost:3000/

    If you are serving your application in a different port from the default one that is 3000, make sure you have updated your client's configuration mentioned in the Prerequisites section and auth.js accordingly.

    License

    This project is licensed under the MIT license. See the LICENSE file for more info.

    This project is bootstrapped with Create React App.

    What is PlusAuth

    PlusAuth helps individuals, teams, and organizations to implement authorization and authentication systems in a secure, flexible and easy way.

    Explore the PlusAuth Website »

    Explore the PlusAuth Docs »

    Explore the PlusAuth Forum »

    About

    React.js starter project demonstrating OIDC authentication using create-react-app and oidc-client.

    Resources

    Stars

    1 star

    Watchers

    3 watching

    Forks

    Releases

    Packages

    Contributors

    Languages