@pickaxeproject/react 4.2.1 → 4.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}Object.defineProperty(exports,"__esModule",{value:!0});var
|
|
1
|
+
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}Object.defineProperty(exports,"__esModule",{value:!0});var n=e(require("axios"));const o=process.env.NEXT_PUBLIC_PICKAXE_API_URL||"";if(!o)throw new Error("[px/react] NEXT_PUBLIC_PICKAXE_API_URL is not defined");const s="undefined"!=typeof window?window.location.hostname:"",t="undefined"!=typeof window?window.location.href:"",i="undefined"!=typeof window&&window.self!==window.top,d=s.includes("pickaxe.co")&&!t.includes("https://studio.pickaxe.co/_embed")&&!i,c=n.default.create(Object.assign(Object.assign({baseURL:o},(!process.env.NODE_ENV||"development"===process.env.NODE_ENV)&&Object.assign({},process.env.NEXT_PUBLIC_PICKAXE_SESSION_TOKEN&&{headers:{"x-pickaxe-session-token":process.env.NEXT_PUBLIC_PICKAXE_SESSION_TOKEN}})),d&&{withCredentials:!0}));exports.default=c;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"axios";const
|
|
1
|
+
import e from"axios";const o=process.env.NEXT_PUBLIC_PICKAXE_API_URL||"";if(!o)throw new Error("[px/react] NEXT_PUBLIC_PICKAXE_API_URL is not defined");const n="undefined"!=typeof window?window.location.hostname:"",s="undefined"!=typeof window?window.location.href:"",i="undefined"!=typeof window&&window.self!==window.top,t=n.includes("pickaxe.co")&&!s.includes("https://studio.pickaxe.co/_embed")&&!i,d=e.create(Object.assign(Object.assign({baseURL:o},(!process.env.NODE_ENV||"development"===process.env.NODE_ENV)&&Object.assign({},process.env.NEXT_PUBLIC_PICKAXE_SESSION_TOKEN&&{headers:{"x-pickaxe-session-token":process.env.NEXT_PUBLIC_PICKAXE_SESSION_TOKEN}})),t&&{withCredentials:!0}));export{d as default};
|