Skip to content

Releases: auth0/auth0-spa-js

v1.19.0

11 Oct 13:53
4f9fcfe
Compare
Choose a tag to compare

Added

v1.18.0

15 Sep 15:28
17ad320
Compare
Choose a tag to compare

Added

Changed

Fixed

v1.17.1

03 Sep 15:32
22162e2
Compare
Choose a tag to compare

Fixed

v1.17.0

04 Aug 14:47
2ebbe54
Compare
Choose a tag to compare

Added

  • Add useFormData to enable application/x-www-form-urlencoded requests #768 (stevehobbsdev)

Changed

Release v1.16.1

07 Jul 16:57
1044378
Compare
Choose a tag to compare

This release fixes an edge case when using logout({ localOnly: true }), where it generates a race condition if you happen to query for SDK state directly after logging out.

Now, logout can return a Promise when using a custom cache implementation. In general, if you're interested in accurately assessing SDK state after logging out locally, you should await the result and act afterwards.

const logout = async () => {
  await auth0.logout({ localOnly: true });
  
  const authed = await isAuthenticated();
}

Fixed

v1.16.0

05 Jul 14:48
ecafb37
Compare
Choose a tag to compare

This release adds a new extensible cache API, that enables you to bring your own cache implementation instead of relying on our built-in in-memory storage and localStorage implementations.

It's a Promise-based API that opens up the possibility to provide a more secure and complex cache to the SDK.

Here's a simple example that shows how sessionStorage support can be added to the cache:

const sessionStorageCache = {
  get(key) {
    return Promise.resolve(JSON.parse(sessionStorage.getItem(key)));
  },

  set(key, value) {
    return Promise.resolve(sessionStorage.setItem(key, JSON.stringify(value)));
  },

  remove(key) {
    sessionStorage.removeItem(key);
    return Promise.resolve();
  },
};

await createAuth0Client({
  domain: '<AUTH0_DOMAIN>',
  client_id: '<AUTH0_CLIENT_ID>',
  redirect_uri: '<MY_CALLBACK_URL>',
  cache: sessionStorageCache
});

You can read more about the cache API in the readme doc.

Added

v1.15.0

29 Apr 14:31
1da10cb
Compare
Choose a tag to compare

Added

Fixed

  • Fix popup blocker showing for loginWithPopup in Firefox & Safari #732 (stevehobbsdev)

v1.14.0

22 Mar 13:36
041ce0a
Compare
Choose a tag to compare

Full Changelog

Added

Changed

  • Add screen_hint parameter to BaseLoginOptions #721 (damieng)

Fixed

  • Updated minor syntax, to allow for TypeScript compiler to be happier #714 (kachihro)
  • Revert [SDK-2183] Add warning when requested scopes differ from retrieved scopes #712 (frederikprijck)

v1.13.6

07 Jan 16:12
42c7c80
Compare
Choose a tag to compare

Changed

Fixed

Security

v1.13.5

08 Dec 14:31
1114554
Compare
Choose a tag to compare

Changed

Fixed

  • [SDK-1739] Recover and logout when throwing invalid_grant on Refresh Token #668 (frederikprijck)

Remarks

This release updates the getUser return type to be more correct. Instead of returning Promise<TUser>, it now returns Promise<TUser | undefined>, which might lead to an Object is possible 'undefined' compiler error in situation where the return value is not checked for being undefined while having set the TypeScript's --strictNullChecks compiler flag to true.