@getflip/bridge
Advanced tools
Comparing version 0.1.0-alpha.2 to 0.1.0-alpha.3
@@ -8,2 +8,3 @@ 'use strict'; | ||
BridgeErrorCode["FORBIDDEN_ORIGIN"] = "FORBIDDEN_ORIGIN"; | ||
BridgeErrorCode["INVALID_REQUEST"] = "INVALID_REQUEST"; | ||
})(exports.BridgeErrorCode || (exports.BridgeErrorCode = {})); | ||
@@ -18,3 +19,4 @@ exports.BridgeMethod = void 0; | ||
const debug = process.env.NODE_ENV === "development"; | ||
var _a$1; | ||
const debug = ((_a$1 = process === null || process === void 0 ? void 0 : process.env) === null || _a$1 === void 0 ? void 0 : _a$1.NODE_ENV) === "development"; | ||
function log(message, details) { | ||
@@ -26,3 +28,4 @@ if (debug) { | ||
const hostAppOrigin = process.env.HOST_APP_ORIGIN || "http://localhost:4200"; | ||
var _a; | ||
const hostAppOrigin = ((_a = process === null || process === void 0 ? void 0 : process.env) === null || _a === void 0 ? void 0 : _a.HOST_APP_ORIGIN) || "http://localhost:4200"; | ||
function postMessage(message) { | ||
@@ -29,0 +32,0 @@ if (!window.top) { |
@@ -1,2 +0,3 @@ | ||
const debug = process.env.NODE_ENV === "development"; | ||
var _a; | ||
const debug = ((_a = process === null || process === void 0 ? void 0 : process.env) === null || _a === void 0 ? void 0 : _a.NODE_ENV) === "development"; | ||
export function log(message, details) { | ||
@@ -3,0 +4,0 @@ if (debug) { |
@@ -0,4 +1,5 @@ | ||
var _a; | ||
import { log } from "../logging"; | ||
import { BridgeErrorCode, } from "../types"; | ||
const hostAppOrigin = process.env.HOST_APP_ORIGIN || "http://localhost:4200"; | ||
const hostAppOrigin = ((_a = process === null || process === void 0 ? void 0 : process.env) === null || _a === void 0 ? void 0 : _a.HOST_APP_ORIGIN) || "http://localhost:4200"; | ||
export function postMessage(message) { | ||
@@ -5,0 +6,0 @@ if (!window.top) { |
@@ -18,3 +18,4 @@ import { GetAvailableLangsResult, GetLangResult } from "./i18n"; | ||
export declare enum BridgeErrorCode { | ||
FORBIDDEN_ORIGIN = "FORBIDDEN_ORIGIN" | ||
FORBIDDEN_ORIGIN = "FORBIDDEN_ORIGIN", | ||
INVALID_REQUEST = "INVALID_REQUEST" | ||
} | ||
@@ -21,0 +22,0 @@ export declare enum BridgeMethod { |
export var BridgeErrorCode; | ||
(function (BridgeErrorCode) { | ||
BridgeErrorCode["FORBIDDEN_ORIGIN"] = "FORBIDDEN_ORIGIN"; | ||
BridgeErrorCode["INVALID_REQUEST"] = "INVALID_REQUEST"; | ||
})(BridgeErrorCode || (BridgeErrorCode = {})); | ||
@@ -5,0 +6,0 @@ export var BridgeMethod; |
{ | ||
"name": "@getflip/bridge", | ||
"version": "0.1.0-alpha.2", | ||
"version": "0.1.0-alpha.3", | ||
"description": "Flip JavaScript Bridge for external integrations.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.cjs.js", |
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
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
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
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
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 2 instances in 1 package
27939
365