@peerboard/core
Advanced tools
Comparing version 0.0.20 to 0.0.21
@@ -61,5 +61,6 @@ "use strict"; | ||
if (!opts.usePathFromQs) { | ||
// Auto resolve redirect | ||
// Auto resolve final location | ||
opts.path = ((options.prefix && options.prefix !== "/") | ||
? document.location.pathname.replace(new RegExp("^/" + trimLeftSlash(options.prefix)), '') | ||
// Cut everything before the prefix to support /{lang}/{prefix}/{peer-board-path} cases | ||
? document.location.pathname.replace(new RegExp(".*/" + trimLeftSlash(options.prefix)), '') | ||
: document.location.pathname) + document.location.search + document.location.hash; | ||
@@ -66,0 +67,0 @@ } |
@@ -76,5 +76,6 @@ 'use strict'; | ||
if (!opts.usePathFromQs) { | ||
// Auto resolve redirect | ||
// Auto resolve final location | ||
opts.path = ((options.prefix && options.prefix !== "/") | ||
? document.location.pathname.replace(new RegExp("^/" + trimLeftSlash(options.prefix)), '') | ||
// Cut everything before the prefix to support /{lang}/{prefix}/{peer-board-path} cases | ||
? document.location.pathname.replace(new RegExp(".*/" + trimLeftSlash(options.prefix)), '') | ||
: document.location.pathname) + document.location.search + document.location.hash; | ||
@@ -81,0 +82,0 @@ } |
@@ -78,5 +78,6 @@ (function (global, factory) { | ||
if (!opts.usePathFromQs) { | ||
// Auto resolve redirect | ||
// Auto resolve final location | ||
opts.path = ((options.prefix && options.prefix !== "/") | ||
? document.location.pathname.replace(new RegExp("^/" + trimLeftSlash(options.prefix)), '') | ||
// Cut everything before the prefix to support /{lang}/{prefix}/{peer-board-path} cases | ||
? document.location.pathname.replace(new RegExp(".*/" + trimLeftSlash(options.prefix)), '') | ||
: document.location.pathname) + document.location.search + document.location.hash; | ||
@@ -83,0 +84,0 @@ } |
{ | ||
"name": "@peerboard/core", | ||
"version": "0.0.20", | ||
"version": "0.0.21", | ||
"description": "peerboard.com frontend components", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
51557
493