@blinkdotnew/dev-sdk 2.4.0 → 2.4.1
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.
- package/dist/index.d.mts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +3 -1
- package/dist/index.mjs +3 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -112,6 +112,8 @@ interface BlinkClientConfig {
|
|
|
112
112
|
* })
|
|
113
113
|
*/
|
|
114
114
|
storage?: StorageAdapter;
|
|
115
|
+
/** Custom core API URL (default: https://core.blink.new). Used to point at a local dev server. */
|
|
116
|
+
coreUrl?: string;
|
|
115
117
|
}
|
|
116
118
|
interface BlinkAuthConfig {
|
|
117
119
|
mode?: 'managed' | 'headless';
|
package/dist/index.d.ts
CHANGED
|
@@ -112,6 +112,8 @@ interface BlinkClientConfig {
|
|
|
112
112
|
* })
|
|
113
113
|
*/
|
|
114
114
|
storage?: StorageAdapter;
|
|
115
|
+
/** Custom core API URL (default: https://core.blink.new). Used to point at a local dev server. */
|
|
116
|
+
coreUrl?: string;
|
|
115
117
|
}
|
|
116
118
|
interface BlinkAuthConfig {
|
|
117
119
|
mode?: 'managed' | 'headless';
|
package/dist/index.js
CHANGED
|
@@ -2970,7 +2970,7 @@ function convertKeysToCamelCase(obj) {
|
|
|
2970
2970
|
}
|
|
2971
2971
|
var HttpClient = class {
|
|
2972
2972
|
authUrl = "https://blink.new";
|
|
2973
|
-
coreUrl
|
|
2973
|
+
coreUrl;
|
|
2974
2974
|
projectId;
|
|
2975
2975
|
publishableKey;
|
|
2976
2976
|
secretKey;
|
|
@@ -2983,6 +2983,8 @@ var HttpClient = class {
|
|
|
2983
2983
|
this.secretKey = config.secretKey || config.serviceToken;
|
|
2984
2984
|
this.getToken = getToken;
|
|
2985
2985
|
this.getValidToken = getValidToken;
|
|
2986
|
+
const envUrl = typeof process !== "undefined" ? process.env?.BLINK_API_URL : void 0;
|
|
2987
|
+
this.coreUrl = config.coreUrl || envUrl || "https://core.blink.new";
|
|
2986
2988
|
}
|
|
2987
2989
|
shouldAttachPublishableKey(path, method) {
|
|
2988
2990
|
if (method !== "GET" && method !== "POST") return false;
|
package/dist/index.mjs
CHANGED
|
@@ -2968,7 +2968,7 @@ function convertKeysToCamelCase(obj) {
|
|
|
2968
2968
|
}
|
|
2969
2969
|
var HttpClient = class {
|
|
2970
2970
|
authUrl = "https://blink.new";
|
|
2971
|
-
coreUrl
|
|
2971
|
+
coreUrl;
|
|
2972
2972
|
projectId;
|
|
2973
2973
|
publishableKey;
|
|
2974
2974
|
secretKey;
|
|
@@ -2981,6 +2981,8 @@ var HttpClient = class {
|
|
|
2981
2981
|
this.secretKey = config.secretKey || config.serviceToken;
|
|
2982
2982
|
this.getToken = getToken;
|
|
2983
2983
|
this.getValidToken = getValidToken;
|
|
2984
|
+
const envUrl = typeof process !== "undefined" ? process.env?.BLINK_API_URL : void 0;
|
|
2985
|
+
this.coreUrl = config.coreUrl || envUrl || "https://core.blink.new";
|
|
2984
2986
|
}
|
|
2985
2987
|
shouldAttachPublishableKey(path, method) {
|
|
2986
2988
|
if (method !== "GET" && method !== "POST") return false;
|
package/package.json
CHANGED