Skip to content
This repository was archived by the owner on Jan 2, 2024. It is now read-only.

Latest commit

 

History

History
39 lines (23 loc) · 1.49 KB

File metadata and controls

39 lines (23 loc) · 1.49 KB

Embedded login

In most real-world scenarios, you will want to have full control over the UI. In these cases, you can use FRAuth to obtain typed callback instances from authentication trees and render the UI in whatever way makes sense for your application.

You can run this sample app with the npm run start:embedded-login command. Please see the Getting Started instructions for more details.

Getting Started

  1. Setup CORS support in an Access Management (AM) instance.

    See Enabling CORS Support in the Documentation.

  2. Create an authentication tree in AM.

    See Creating a User Authentication Tree in the Documentation.

  3. Clone this repo:

    git clone https://github.com/ForgeRock/forgerock-javascript-sdk.git
    
  4. In the root folder of the repo, use NPM to install dependencies:

    npm install
    
  5. Open samples/embedded-login/.env.example. Copy the file in the same directory and name it .env. Fill in the values in this file with your values.

  6. Run the Embedded Login application

    npm run start:embedded-login
    
  7. Edit your /etc/hosts file to point your localhost (e.g. 127.0.0.1) to sdkapp.example.com

  8. In a supported web browser, navigate to https://sdkapp.example.com:8443