@featurevisor/types 0.23.0 → 0.25.0
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/CHANGELOG.md +22 -0
- package/lib/index.d.ts +3 -2
- package/package.json +2 -2
- package/src/index.ts +6 -2
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,28 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [0.25.0](https://github.com/fahad19/featurevisor/compare/v0.24.0...v0.25.0) (2023-05-22)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* Pretty JSON ([#75](https://github.com/fahad19/featurevisor/issues/75)) ([322bc3a](https://github.com/fahad19/featurevisor/commit/322bc3a7f1676cf32e19f693d5736dc8f1db8d5a))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# [0.24.0](https://github.com/fahad19/featurevisor/compare/v0.23.0...v0.24.0) (2023-05-21)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Features
|
|
21
|
+
|
|
22
|
+
* ranges in datafiles as tuples ([#74](https://github.com/fahad19/featurevisor/issues/74)) ([07a3d92](https://github.com/fahad19/featurevisor/commit/07a3d9292f4038ebd68338bb905a34b2f13d36d9))
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
6
28
|
# [0.23.0](https://github.com/fahad19/featurevisor/compare/v0.22.0...v0.23.0) (2023-05-20)
|
|
7
29
|
|
|
8
30
|
**Note:** Version bump only for package @featurevisor/types
|
package/lib/index.d.ts
CHANGED
|
@@ -108,10 +108,12 @@ export type BucketValue = number;
|
|
|
108
108
|
* Datafile-only types
|
|
109
109
|
*/
|
|
110
110
|
export type Percentage = number;
|
|
111
|
-
export interface
|
|
111
|
+
export interface RangeObject {
|
|
112
112
|
start: Percentage;
|
|
113
113
|
end: Percentage;
|
|
114
114
|
}
|
|
115
|
+
export type RangeTuple = [Percentage, Percentage];
|
|
116
|
+
export type Range = RangeObject | RangeTuple;
|
|
115
117
|
export interface Allocation {
|
|
116
118
|
variation: VariationValue;
|
|
117
119
|
percentage?: Percentage;
|
|
@@ -192,7 +194,6 @@ export interface ParsedFeature {
|
|
|
192
194
|
* with consistent bucketing
|
|
193
195
|
*/
|
|
194
196
|
export interface ExistingFeature {
|
|
195
|
-
revision: string;
|
|
196
197
|
variations: {
|
|
197
198
|
value: VariationValue;
|
|
198
199
|
weight: Weight;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@featurevisor/types",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.25.0",
|
|
4
4
|
"description": "Common Typescript types for Featurevisor",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -41,5 +41,5 @@
|
|
|
41
41
|
"url": "https://github.com/fahad19/featurevisor/issues"
|
|
42
42
|
},
|
|
43
43
|
"license": "MIT",
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "33fbe32f62eea51b71b7377bd4d890f319838be6"
|
|
45
45
|
}
|
package/src/index.ts
CHANGED
|
@@ -199,11 +199,16 @@ export type BucketValue = number; // 0 to 100,000 (100% * 1000 to include three
|
|
|
199
199
|
*/
|
|
200
200
|
export type Percentage = number; // 0 to 100,000 (100% * 1000 to include three decimal places in same integer)
|
|
201
201
|
|
|
202
|
-
|
|
202
|
+
// @TODO: remove this in next breaking semver
|
|
203
|
+
export interface RangeObject {
|
|
203
204
|
start: Percentage; // 0 to 100k
|
|
204
205
|
end: Percentage; // 0 to 100k
|
|
205
206
|
}
|
|
206
207
|
|
|
208
|
+
export type RangeTuple = [Percentage, Percentage]; // 0 to 100k
|
|
209
|
+
|
|
210
|
+
export type Range = RangeObject | RangeTuple;
|
|
211
|
+
|
|
207
212
|
export interface Allocation {
|
|
208
213
|
variation: VariationValue;
|
|
209
214
|
percentage?: Percentage; // @TODO: remove it in next breaking semver
|
|
@@ -302,7 +307,6 @@ export interface ParsedFeature {
|
|
|
302
307
|
* with consistent bucketing
|
|
303
308
|
*/
|
|
304
309
|
export interface ExistingFeature {
|
|
305
|
-
revision: string;
|
|
306
310
|
variations: {
|
|
307
311
|
// @TODO: use Exclude with Variation?
|
|
308
312
|
value: VariationValue;
|