Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-oauth2-code-pkce

Package Overview
Dependencies
Maintainers
1
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-oauth2-code-pkce - npm Package Compare versions

Comparing version 1.10.0 to 1.10.1

7

dist/AuthContext.js

@@ -157,2 +157,6 @@ "use strict";

}, [token]); // This token dependency removes the old, and registers a new Interval when a new token is fetched.
// This ref is used to make sure the 'fetchTokens' call is only made once.
// Multiple calls with the same code will, and should, return an error from the API
// See: https://beta.reactjs.org/learn/synchronizing-with-effects#how-to-handle-the-effect-firing-twice-in-development
const didFetchTokens = (0, react_1.useRef)(false);
// Runs once on page load

@@ -170,3 +174,4 @@ (0, react_1.useEffect)(() => {

}
else {
else if (!didFetchTokens.current) {
didFetchTokens.current = true;
// Request token from auth server with the auth code

@@ -173,0 +178,0 @@ (0, authentication_1.fetchTokens)(config)

2

package.json
{
"name": "react-oauth2-code-pkce",
"version": "1.10.0",
"version": "1.10.1",
"description": "Provider agnostic react package for OAuth2 Authorization Code flow with PKCE",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -118,3 +118,3 @@ # react-oauth2-code-pkce · [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/soofstad/react-oauth2-pkce/blob/main/LICENSE) [![npm version](https://img.shields.io/npm/v/react-oauth2-code-pkce)](https://www.npmjs.com/package/react-oauth2-code-pkce) ![CI](https://github.com/soofstad/react-oauth2-pkce/actions/workflows/tests.yaml/badge.svg)

tokenEndpoint: string // Required
// Which URL the auth provider should redirect the user after loging out
// Which URL the auth provider should redirect the user after successfull authentication/login
redirectUri: string // Required

@@ -125,4 +125,3 @@ // Which scopes to request for the auth token

logoutEndpoint?: string // default: null
// Should be used by the auth provider to decide which URL to redirect
// the user to after logout
// Which URL the auth provider should redirect the user to after logout
logoutRedirect?: string // default: null

@@ -129,0 +128,0 @@ // Optionally provide a callback function to run _before_ the

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc