Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/express-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"start": "node server.mjs"
},
"dependencies": {
"@microsoft/feature-management": "2.1.0",
"@microsoft/feature-management": "latest",
"express": "^4.21.2"
}
}
4 changes: 2 additions & 2 deletions examples/quote-of-the-day/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
},
"dependencies": {
"@azure/app-configuration-provider": "latest",
"@microsoft/feature-management": "2.1.0",
"@microsoft/feature-management-applicationinsights-node": "2.1.0",
"@microsoft/feature-management": "latest",
"@microsoft/feature-management-applicationinsights-node": "latest",
"applicationinsights": "^2.9.6",
"dotenv": "^16.5.0",
"express": "^4.19.2"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@microsoft/feature-management-applicationinsights-browser",
"version": "2.1.0",
"version": "2.2.0",
"description": "Feature Management Application Insights Plugin for Browser provides a solution for sending feature flag evaluation events produced by the Feature Management library.",
"main": "./dist/esm/index.js",
"module": "./dist/esm/index.js",
Expand Down Expand Up @@ -46,7 +46,7 @@
},
"dependencies": {
"@microsoft/applicationinsights-web": "^3.3.2",
"@microsoft/feature-management": "2.1.0"
"@microsoft/feature-management": "2.2.0"
}
}

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.

export const VERSION = "2.1.0";
export const VERSION = "2.2.0";
4 changes: 2 additions & 2 deletions src/feature-management-applicationinsights-node/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@microsoft/feature-management-applicationinsights-node",
"version": "2.1.0",
"version": "2.2.0",
"description": "Feature Management Application Insights Plugin for Node.js provides a solution for sending feature flag evaluation events produced by the Feature Management library.",
"main": "./dist/commonjs/index.js",
"module": "./dist/esm/index.js",
Expand Down Expand Up @@ -45,7 +45,7 @@
},
"dependencies": {
"applicationinsights": "^2.9.6",
"@microsoft/feature-management": "2.1.0"
"@microsoft/feature-management": "2.2.0"
}
}

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.

export const VERSION = "2.1.0";
export const VERSION = "2.2.0";
123 changes: 121 additions & 2 deletions src/feature-management/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions src/feature-management/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@microsoft/feature-management",
"version": "2.1.0",
"version": "2.2.0",
"description": "Feature Management is a library for enabling/disabling features at runtime. Developers can use feature flags in simple use cases like conditional statement to more advanced scenarios like conditionally adding routes.",
"main": "./dist/commonjs/index.js",
"module": "./dist/esm/index.js",
Expand All @@ -18,7 +18,7 @@
"dev": "rollup --config --watch",
"lint": "eslint src/ test/ --ignore-pattern test/browser/testcases.js",
"fix-lint": "eslint src/ test/ --fix --ignore-pattern test/browser/testcases.js",
"test": "mocha out/*.test.{js,cjs,mjs} --parallel",
"test": "mocha out/test/*.test.{js,cjs,mjs} --parallel",
"test-browser": "npx playwright install chromium && npx playwright test"
},
"repository": {
Expand Down Expand Up @@ -47,6 +47,7 @@
"rimraf": "^5.0.5",
"rollup": "^4.22.4",
"rollup-plugin-dts": "^6.1.0",
"sinon": "^18.0.0",
"tslib": "^2.6.2",
"typescript": "^5.3.3"
},
Expand Down
11 changes: 5 additions & 6 deletions src/feature-management/src/featureManager.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.

import { TimeWindowFilter } from "./filter/TimeWindowFilter.js";
import { IFeatureFilter } from "./filter/FeatureFilter.js";
import { TimeWindowFilter } from "./filter/timeWindowFilter.js";
import { IFeatureFilter } from "./filter/featureFilter.js";
import { FeatureFlag, RequirementType, VariantDefinition } from "./schema/model.js";
import { IFeatureFlagProvider } from "./featureProvider.js";
import { TargetingFilter } from "./filter/TargetingFilter.js";
import { Variant } from "./variant/Variant.js";
import { IFeatureManager } from "./IFeatureManager.js";
import { IFeatureFlagProvider, IFeatureManager } from "./model.js";
import { TargetingFilter } from "./filter/targetingFilter.js";
import { Variant } from "./variant/variant.js";
import { ITargetingContext, ITargetingContextAccessor } from "./common/targetingContext.js";
import { isTargetedGroup, isTargetedPercentile, isTargetedUser } from "./common/targetingEvaluator.js";

Expand Down
14 changes: 1 addition & 13 deletions src/feature-management/src/featureProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,9 @@

import { IGettable } from "./gettable.js";
import { FeatureFlag, FeatureManagementConfiguration, FEATURE_MANAGEMENT_KEY, FEATURE_FLAGS_KEY } from "./schema/model.js";
import { IFeatureFlagProvider } from "./model.js";
import { validateFeatureFlag } from "./schema/validator.js";

export interface IFeatureFlagProvider {
/**
* Get all feature flags.
*/
getFeatureFlags(): Promise<FeatureFlag[]>;

/**
* Get a feature flag by name.
* @param featureName The name of the feature flag.
*/
getFeatureFlag(featureName: string): Promise<FeatureFlag | undefined>;
}

/**
* A feature flag provider that uses a map-like configuration to provide feature flags.
*/
Expand Down
33 changes: 0 additions & 33 deletions src/feature-management/src/filter/TimeWindowFilter.ts

This file was deleted.

Loading