Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@launchdarkly/js-server-sdk-common

Package Overview
Dependencies
Maintainers
1
Versions
57
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@launchdarkly/js-server-sdk-common - npm Package Compare versions

Comparing version 2.3.0-alpha.0 to 2.3.0-alpha.1

2

dist/api/options/LDOptions.d.ts

@@ -234,4 +234,4 @@ import { LDClientContext, LDLogger, subsystem, VoidFunction } from '@launchdarkly/js-sdk-common';

};
evaluationHooks?: Hook[];
hooks?: Hook[];
}
//# sourceMappingURL=LDOptions.d.ts.map

@@ -36,3 +36,3 @@ import { internal, LDContext, LDEvaluationDetail, LDEvaluationDetailTyped, Platform } from '@launchdarkly/js-sdk-common';

private diagnosticsManager?;
private evaluationHooks?;
private hooks?;
/**

@@ -54,3 +54,3 @@ * Intended for use by platform specific client implementations.

private executeBeforeEvaluation;
private prepareEvaluationHooks;
private prepareHooks;
private typedEval;

@@ -57,0 +57,0 @@ boolVariation(key: string, context: LDContext, defaultValue: boolean): Promise<boolean>;

@@ -59,3 +59,3 @@ "use strict";

// TODO: USE CONFIG
this.evaluationHooks = options.evaluationHooks;
this.hooks = options.hooks;
if (!sdkKey && !config.offline) {

@@ -165,3 +165,3 @@ throw new Error('You must configure the client with an SDK key');

async withHooks(key, context, defaultValue, methodName, method) {
const { hooks, hookContext } = this.prepareEvaluationHooks(key, context, defaultValue, methodName);
const { hooks, hookContext } = this.prepareHooks(key, context, defaultValue, methodName);
const hookData = this.executeBeforeEvaluation(hooks, hookContext);

@@ -178,4 +178,4 @@ const result = await method();

}
prepareEvaluationHooks(key, context, defaultValue, methodName) {
const hooks = [...(this.evaluationHooks || [])];
prepareHooks(key, context, defaultValue, methodName) {
const hooks = [...(this.hooks || [])];
const hookContext = {

@@ -234,3 +234,3 @@ key,

async migrationVariation(key, context, defaultValue) {
const { hooks, hookContext } = this.prepareEvaluationHooks(key, context, defaultValue, MIGRATION_VARIATION_METHOD_NAME);
const { hooks, hookContext } = this.prepareHooks(key, context, defaultValue, MIGRATION_VARIATION_METHOD_NAME);
const hookData = this.executeBeforeEvaluation(hooks, hookContext);

@@ -237,0 +237,0 @@ const convertedContext = js_sdk_common_1.Context.fromLDContext(context);

{
"name": "@launchdarkly/js-server-sdk-common",
"version": "2.3.0-alpha.0",
"version": "2.3.0-alpha.1",
"type": "commonjs",

@@ -5,0 +5,0 @@ "main": "./dist/index.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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc