supertokens-website
Advanced tools
Comparing version 16.0.7 to 16.0.8
@@ -10,2 +10,5 @@ # Changelog | ||
## [16.0.8] - 2023-04-25 | ||
- Passes windowHandler's localstorage to browser-tabs-lock as well. | ||
## [16.0.7] - 2023-04-19 | ||
@@ -12,0 +15,0 @@ - Relaxes test constraint related to legacy axios interceptor. |
@@ -177,3 +177,6 @@ "use strict"; | ||
windowHandler_1.default.init(options.windowHandler); | ||
lockFactory_1.default.init(options.lockFactory); | ||
lockFactory_1.default.init( | ||
options.lockFactory, | ||
windowHandler_1.default.getReferenceOrThrow().windowHandler.localStorage | ||
); | ||
var config = (0, utils_1.validateAndNormaliseInputOrThrowError)(options); | ||
@@ -180,0 +183,0 @@ var recipeImpl = new supertokens_js_override_1.default( |
import { LockFactory } from "./types"; | ||
import { StorageHandler } from "../windowHandler/types"; | ||
export default class LockFactoryReference { | ||
@@ -6,5 +7,5 @@ lockFactory: LockFactory; | ||
constructor(lockFactory: LockFactory); | ||
static init(lockFactory?: LockFactory): void; | ||
static init(lockFactory?: LockFactory, storageHandler?: StorageHandler): void; | ||
static getReferenceOrThrow(): LockFactoryReference; | ||
} | ||
export { LockFactoryReference }; |
@@ -5,4 +5,6 @@ "use strict"; | ||
var browser_tabs_lock_1 = require("browser-tabs-lock"); | ||
var defaultFactory = function () { | ||
return Promise.resolve(new browser_tabs_lock_1.default()); | ||
var defaultFactory = function (storageHandler) { | ||
return function () { | ||
return Promise.resolve(new browser_tabs_lock_1.default(storageHandler)); | ||
}; | ||
}; | ||
@@ -13,3 +15,3 @@ var LockFactoryReference = /** @class */ (function () { | ||
} | ||
LockFactoryReference.init = function (lockFactory) { | ||
LockFactoryReference.init = function (lockFactory, storageHandler) { | ||
// This is copied from the other XXXReference clasess | ||
@@ -20,3 +22,3 @@ if (this.instance !== undefined) { | ||
this.instance = new LockFactoryReference( | ||
lockFactory !== null && lockFactory !== void 0 ? lockFactory : defaultFactory | ||
lockFactory !== null && lockFactory !== void 0 ? lockFactory : defaultFactory(storageHandler) | ||
); | ||
@@ -23,0 +25,0 @@ }; |
@@ -1,2 +0,2 @@ | ||
export declare const package_version = "16.0.7"; | ||
export declare const package_version = "16.0.8"; | ||
export declare const supported_fdi: string[]; |
@@ -18,3 +18,3 @@ "use strict"; | ||
*/ | ||
exports.package_version = "16.0.7"; | ||
exports.package_version = "16.0.8"; | ||
exports.supported_fdi = ["1.16"]; |
{ | ||
"name": "supertokens-website", | ||
"version": "16.0.7", | ||
"version": "16.0.8", | ||
"description": "frontend sdk for website to be used for auth solution.", | ||
"main": "index.js", | ||
"dependencies": { | ||
"browser-tabs-lock": "^1.2.14", | ||
"browser-tabs-lock": "^1.3.0", | ||
"supertokens-js-override": "^0.0.4" | ||
@@ -9,0 +9,0 @@ }, |
375044
7413
Updatedbrowser-tabs-lock@^1.3.0