@module-federation/sdk
Advanced tools
Comparing version 0.0.0-next-20240131231251 to 0.0.0-next-20240201072006
@@ -111,12 +111,2 @@ 'use strict'; | ||
var DEBUG_LOG = "[ FEDERATION DEBUG ]"; | ||
function safeGetLocalStorageItem() { | ||
try { | ||
if (typeof window !== "undefined" && window.localStorage) { | ||
return localStorage.getItem(BROWSER_LOG_KEY) === BROWSER_LOG_VALUE; | ||
} | ||
} catch (error) { | ||
return typeof typeof document !== "undefined"; | ||
} | ||
return false; | ||
} | ||
var Logger = /*#__PURE__*/ function() { | ||
@@ -128,3 +118,3 @@ function Logger(identifier) { | ||
this.identifier = identifier || DEBUG_LOG; | ||
if (isBrowserEnv() && safeGetLocalStorageItem()) { | ||
if (isBrowserEnv() && localStorage.getItem(BROWSER_LOG_KEY) === BROWSER_LOG_VALUE) { | ||
this.enable = true; | ||
@@ -131,0 +121,0 @@ } else if (isDebugMode()) { |
@@ -107,12 +107,2 @@ function _define_property$2(obj, key, value) { | ||
var DEBUG_LOG = "[ FEDERATION DEBUG ]"; | ||
function safeGetLocalStorageItem() { | ||
try { | ||
if (typeof window !== "undefined" && window.localStorage) { | ||
return localStorage.getItem(BROWSER_LOG_KEY) === BROWSER_LOG_VALUE; | ||
} | ||
} catch (error) { | ||
return typeof typeof document !== "undefined"; | ||
} | ||
return false; | ||
} | ||
var Logger = /*#__PURE__*/ function() { | ||
@@ -124,3 +114,3 @@ function Logger(identifier) { | ||
this.identifier = identifier || DEBUG_LOG; | ||
if (isBrowserEnv() && safeGetLocalStorageItem()) { | ||
if (isBrowserEnv() && localStorage.getItem(BROWSER_LOG_KEY) === BROWSER_LOG_VALUE) { | ||
this.enable = true; | ||
@@ -127,0 +117,0 @@ } else if (isDebugMode()) { |
@@ -26,3 +26,3 @@ 'use strict'; | ||
var webpackLocationWithDetail = webpackErrLocation.replace(/[^\(\)]+/, "").slice(1, -1); | ||
var webpackPath = webpackLocationWithDetail.split(":").slice(0, -2)[0]; | ||
var webpackPath = webpackLocationWithDetail.split(":").slice(0, -2).join(":"); | ||
if ((options === null || options === void 0 ? void 0 : options.framework) === "nextjs") { | ||
@@ -29,0 +29,0 @@ if (webpackPath.endsWith("webpack.js")) { |
@@ -18,3 +18,3 @@ import path from 'path'; | ||
var webpackLocationWithDetail = webpackErrLocation.replace(/[^\(\)]+/, "").slice(1, -1); | ||
var webpackPath = webpackLocationWithDetail.split(":").slice(0, -2)[0]; | ||
var webpackPath = webpackLocationWithDetail.split(":").slice(0, -2).join(":"); | ||
if ((options === null || options === void 0 ? void 0 : options.framework) === "nextjs") { | ||
@@ -21,0 +21,0 @@ if (webpackPath.endsWith("webpack.js")) { |
{ | ||
"name": "@module-federation/sdk", | ||
"version": "0.0.0-next-20240131231251", | ||
"version": "0.0.0-next-20240201072006", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "description": "A sdk for support module federation", |
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
102623
2536