data-monitor-javascript-sdk
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -0,1 +1,8 @@ | ||
## [1.0.1](https://github.com/factset/data-monitor-javascript-sdk/compare/1.0.0...1.0.1) (2022-06-17) | ||
### Bug Fixes | ||
* **browser:** ensure references to process do not occur in the browser ([cf72a5f](https://github.com/factset/data-monitor-javascript-sdk/commit/cf72a5fb4b97e60a257a11a04cd3781ff86b1b69)) | ||
# 1.0.0 (2021-04-13) | ||
@@ -2,0 +9,0 @@ |
@@ -1,2 +0,1 @@ | ||
const { DATA_MONITOR_ENV } = process.env; | ||
export var Environment; | ||
@@ -8,5 +7,3 @@ (function (Environment) { | ||
const environments = Object.values(Environment); | ||
let env = DATA_MONITOR_ENV && environments.includes(DATA_MONITOR_ENV) | ||
? DATA_MONITOR_ENV | ||
: Environment.PROD; | ||
let env = seedEnvironment(); | ||
export function getIframeUrl() { | ||
@@ -26,2 +23,11 @@ switch (env) { | ||
} | ||
function seedEnvironment() { | ||
if (typeof process === 'undefined') { | ||
return Environment.PROD; | ||
} | ||
const { DATA_MONITOR_ENV } = process.env; | ||
return DATA_MONITOR_ENV && environments.includes(DATA_MONITOR_ENV) | ||
? DATA_MONITOR_ENV | ||
: Environment.PROD; | ||
} | ||
//# sourceMappingURL=env.js.map |
import { OnParams, OnceParams, InitOptions } from './types'; | ||
import { ProxySubscriptionCollection } from './proxy-subscription-collection'; | ||
export declare const VERSION = "0.0.0"; | ||
export declare const VERSION = "1.0.1"; | ||
export * from './types'; | ||
@@ -5,0 +5,0 @@ export { Environment } from './env'; |
@@ -6,3 +6,3 @@ import { createIframe, sendOn, sendOnce, sendInit } from './events'; | ||
import { resolveFields } from './data-point/resolve-fields'; | ||
export const VERSION = '0.0.0'; | ||
export const VERSION = '1.0.1'; | ||
export * from './types'; | ||
@@ -9,0 +9,0 @@ export { Environment } from './env'; |
{ | ||
"name": "data-monitor-javascript-sdk", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"main": "dist/lib-modules/index.js", | ||
"types": "dist/lib-modules/index.d.ts", | ||
"sideEffects": false, | ||
"engines": { | ||
"node": "^10.14.0 || ^12.8.1" | ||
}, | ||
"publishConfig": { | ||
@@ -16,2 +13,6 @@ "registry": "https://registry.npmjs.org" | ||
], | ||
"repository": { | ||
"url": "https://github.com/factset/data-monitor-javascript-sdk", | ||
"type": "git" | ||
}, | ||
"scripts": { | ||
@@ -24,4 +25,2 @@ "clean": "rm -rf dist/", | ||
"build": "yarn clean && tsc", | ||
"build:global": "yarn build && webpack", | ||
"build:sdk": "bash ./scripts/build-sdk.sh", | ||
"dev": "yarn clean && tsc -w", | ||
@@ -51,7 +50,5 @@ "test": "jest --coverage", | ||
"tslint-config-prettier": "^1.18.0", | ||
"typescript": "~3.8.0", | ||
"webpack": "^4.44.1", | ||
"webpack-cli": "^3.3.12" | ||
"typescript": "~3.8.0" | ||
}, | ||
"license": "Apache License 2.0" | ||
} |
@@ -55,6 +55,6 @@ # Data Monitor Javascript SDK | ||
// pause/resume realtime data updates based on page visibility | ||
document.addEventListener('visibilitychange', isVisible => { | ||
document.addEventListener('visibilitychange', () => { | ||
if (!subscriptionCollection) return; | ||
if (isVisible) { | ||
if (document.visibilityState === 'visible') { | ||
subscriptionCollection.resume(); | ||
@@ -61,0 +61,0 @@ } else { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
16
1230
0
147758
76
1