Commit Graph

159 Commits

Author SHA1 Message Date
OpenFeature Bot 04139affcb
chore(main): release server-sdk 1.19.0 (#1181)
🤖 I have created a release *beep* *boop*
---


##
[1.19.0](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.18.0...server-sdk-v1.19.0)
(2025-08-14)


###  New Features

* add evaluation-scoped hook data
([#1216](https://github.com/open-feature/js-sdk/issues/1216))
([07af3a9](07af3a9eda))


### 🐛 Bug Fixes

* update core dep
([#1228](https://github.com/open-feature/js-sdk/issues/1228))
([845d24c](845d24c5fe))


### 🧹 Chore

* update node to v20+
([#1203](https://github.com/open-feature/js-sdk/issues/1203))
([1f33453](1f33453c23))


### 📚 Documentation

* Clarify the behavior of setProviderAndWait
([#1180](https://github.com/open-feature/js-sdk/issues/1180))
([4fe8d87](4fe8d87a2e))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2025-08-14 15:57:34 -04:00
Todd Baert 845d24c5fe
fix: update core dep (#1228)
As astutely pointed out by @JasperJuergensen in
https://github.com/open-feature/js-sdk/issues/1227, we added API surface
in core which we use in the latest web, but did't accordingly update the
min version of core in web.

(I also updated the min core version in server, just because).

Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2025-08-14 13:03:20 -04:00
Michael Beemer 07af3a9eda
feat: add evaluation-scoped hook data (#1216)
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2025-07-18 15:08:01 -04:00
Todd Baert 1f33453c23
chore: update node to v20+ (#1203)
node v18 is now EOL

Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2025-05-29 19:38:31 +00:00
Michael Beemer 4fe8d87a2e
docs: Clarify the behavior of setProviderAndWait (#1180)
## This PR

- Updates readme examples to include a try/catch around
setProviderAndWait
- Improves the setProviderAndWait JS Doc

### Related Issues

Fixes #1179

### Notes

https://cloud-native.slack.com/archives/C0344AANLA1/p1745326882304199

---------

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2025-04-23 13:16:18 -04:00
OpenFeature Bot aff60f6776
chore(main): release server-sdk 1.18.0 (#1153)
🤖 I have created a release *beep* *boop*
---


##
[1.18.0](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.17.1...server-sdk-v1.18.0)
(2025-04-11)


###  New Features

* add a top-level method for accessing providers
([#1152](https://github.com/open-feature/js-sdk/issues/1152))
([ae8fce8](ae8fce8753))
* add support for abort controllers to event handlers
([#1151](https://github.com/open-feature/js-sdk/issues/1151))
([6a22483](6a224830fa))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Co-authored-by: Lukas Reining <lukas.reining@codecentric.de>
2025-04-11 14:30:17 +02:00
Michael Beemer ae8fce8753
feat: add a top-level method for accessing providers (#1152)
## This PR

- add a top-level method for accessing providers

### Notes

While working on some improvements to the way Suspense works in the
React SDK, I ran into a few scenarios were having access to the provider
itself was important. I needed a way to confidently tell that a provider
was the noop provider since it has special properties like never being
in a ready state. There are a few ways could could achieve this but I
noticed that the Java SDK [already has
methods](https://github.com/open-feature/java-sdk/blob/main/src/main/java/dev/openfeature/sdk/OpenFeatureAPI.java#L279)
that expose the provider. It also allowed me to improve some of our
existing tests.

### How to test

Unit tests have been updated accordingly.

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2025-03-06 20:50:06 +00:00
Michael Beemer 6a224830fa
feat: add support for abort controllers to event handlers (#1151)
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2025-02-26 16:17:28 -05:00
OpenFeature Bot 045842027c
chore(main): release server-sdk 1.17.1 (#1133)
🤖 I have created a release *beep* *boop*
---


##
[1.17.1](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.17.0...server-sdk-v1.17.1)
(2025-02-07)


### 🐛 Bug Fixes

* msg missing when providers return err resolutions
([#1134](https://github.com/open-feature/js-sdk/issues/1134))
([bc9f6e4](bc9f6e44da))


### 🧹 Chore

* update core peer
([8bbd43e](8bbd43e579))


### 📚 Documentation

* fix eval context link
([#1132](https://github.com/open-feature/js-sdk/issues/1132))
([f6bc695](f6bc6951a3))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
2025-02-07 20:26:32 +00:00
Todd Baert 8bbd43e579 chore: update core peer
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2025-02-07 15:22:52 -05:00
Todd Baert bc9f6e44da
fix: msg missing when providers return err resolutions (#1134)
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2025-02-06 13:39:55 -05:00
Michael Beemer f6bc6951a3
docs: fix eval context link (#1132)
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2025-02-05 16:23:35 -05:00
OpenFeature Bot edab97019a
chore(main): release server-sdk 1.17.0 (#1104)
🤖 I have created a release *beep* *boop*
---


##
[1.17.0](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.16.2...server-sdk-v1.17.0)
(2024-12-18)

### ⚠ BREAKING CHANGES

The signature of the `finally` hook stage has been changed. The
signature now includes the `evaluation details`, as per the [OpenFeature
specification](https://openfeature.dev/specification/sections/hooks#requirement-438).
Note that since hooks are still `experimental,` this does not constitute
a change requiring a new major version. To migrate, update any hook that
implements the `finally` stage to accept `evaluation details` as the
second argument.

* add evaluation details to finally hook
([#1087](https://github.com/open-feature/js-sdk/issues/1087))
([2135254](2135254c4b))

###  New Features

* add evaluation details to finally hook
([#1087](https://github.com/open-feature/js-sdk/issues/1087))
([2135254](2135254c4b))


### 📚 Documentation

* fix comment in README for Hook’s after method
([#1103](https://github.com/open-feature/js-sdk/issues/1103))
([e335615](e3356157d5))


### 🔄 Refactoring

* improve track interface for providers
([#1100](https://github.com/open-feature/js-sdk/issues/1100))
([5e5b160](5e5b160221))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
Co-authored-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-12-18 13:53:23 -05:00
Michael Beemer 2135254c4b
feat: add evaluation details to finally hook (#1087)
## This PR

- adds evaluation details to the `finally` stage in hooks.

### Notes

This breaks the signature of the `finally` stages based on [this spec
enhancement](https://github.com/open-feature/spec/pull/280). It is
**not** considered a breaking change to the SDK because hooks are marked
as experimental in the spec, and the change has no impact on known
hooks.

The noteworthy change to the interface is:

```diff
- finally?(hookContext: Readonly<HookContext<T>>, hookHints?: HookHints): HooksReturn;
+ finally?(hookContext: Readonly<HookContext<T>>, evaluationDetails: EvaluationDetails<T>, hookHints?: HookHints): HooksReturn;
```

### Follow-up Tasks

- Update the JS contribs repo

---------

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-12-12 13:49:09 +00:00
Michael Beemer 5e5b160221
refactor: improve track interface for providers (#1100)
## This PR

- updates the context and trackingEventDetails on the tracking interface
to not be optional since they're always supplied by the SDK.

### Notes

This is a small QoL improvement for provider devs implementing the
tracking interface.

### How to test

The SDK still compiles, and the tests don't need to be modified.

---------

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-12-11 20:09:12 +00:00
Christian Llontop e3356157d5
docs: fix comment in README for Hook’s after method (#1103)
## This PR

- Fixes incorrect comment in the README for the Hook implementation's
`after` method.

Signed-off-by: Christian Llontop <me@chrisllontop.com>
2024-12-10 14:09:46 -05:00
OpenFeature Bot 1ba149d8e5
chore(main): release server-sdk 1.16.2 (#1079)
🤖 I have created a release *beep* *boop*
---


##
[1.16.2](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.16.1...server-sdk-v1.16.2)
(2024-11-07)


### 🧹 Chore

* loosen peer dependency requirements, remove some ci automation
([#1080](https://github.com/open-feature/js-sdk/issues/1080))
([ef3ba21](ef3ba2167a))


### 🚀 Performance

* avoid using exceptions for flow control
([#1074](https://github.com/open-feature/js-sdk/issues/1074))
([26264d6](26264d6d09))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-11-07 12:16:03 -05:00
Todd Baert ef3ba2167a
chore: loosen peer dependency requirements, remove some ci automation (#1080)
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2024-11-07 12:04:41 -05:00
Michael Beemer 26264d6d09
perf: avoid using exceptions for flow control (#1074)
## This PR

- avoids using error codes as flow control during an evaluation

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-11-06 21:50:01 +00:00
OpenFeature Bot 0cc2590d02
chore(main): release server-sdk 1.16.1 (#1070)
🤖 I have created a release *beep* *boop*
---


##
[1.16.1](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.16.0...server-sdk-v1.16.1)
(2024-10-29)


### 📚 Documentation

* add tracking sections
([#1068](https://github.com/open-feature/js-sdk/issues/1068))
([e131faf](e131faffad))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
2024-10-29 13:15:42 -04:00
Todd Baert e131faffad
docs: add tracking sections (#1068)
- adds tracking to all relevant READMEs

---------

Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2024-10-29 13:12:55 -04:00
OpenFeature Bot 278cf3fe70
chore(main): release server-sdk 1.16.0 (#1042)
🤖 I have created a release *beep* *boop*
---


##
[1.16.0](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.15.1...server-sdk-v1.16.0)
(2024-10-29)


###  New Features

* implement tracking as per spec
([#1020](https://github.com/open-feature/js-sdk/issues/1020))
([80f182e](80f182e1af))


### 🧹 Chore

* import type lint rule and fixes
([#1039](https://github.com/open-feature/js-sdk/issues/1039))
([01fcb93](01fcb933d2))
* **main:** release core 1.5.0
([#1040](https://github.com/open-feature/js-sdk/issues/1040))
([fe3ad8e](fe3ad8eeb9))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-10-29 11:55:57 -04:00
OpenFeature Bot fe3ad8eeb9
chore(main): release core 1.5.0 (#1040)
🤖 I have created a release *beep* *boop*
---


##
[1.5.0](https://github.com/open-feature/js-sdk/compare/core-v1.4.0...core-v1.5.0)
(2024-10-29)


###  New Features

* implement tracking as per spec
([#1020](https://github.com/open-feature/js-sdk/issues/1020))
([80f182e](80f182e1af))


### 🧹 Chore

* import type lint rule and fixes
([#1039](https://github.com/open-feature/js-sdk/issues/1039))
([01fcb93](01fcb933d2))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
Co-authored-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
2024-10-29 15:24:16 +00:00
Todd Baert 80f182e1af
feat: implement tracking as per spec (#1020)
📣 This was a draft for a while, but is now ready for review! 📣

This implements tracking as per spec, in the server, web, and react
SDKs.
I don't think the Angular or Nest SDKs need specific implementations,
but please advise (cc @luizgribeiro @lukas-reining).

Fixes: https://github.com/open-feature/js-sdk/issues/1033
Fixes: https://github.com/open-feature/js-sdk/issues/1034

---------

Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2024-10-29 13:46:08 +00:00
Todd Baert 01fcb933d2
chore: import type lint rule and fixes (#1039)
Inspired by [this
comment](https://github.com/open-feature/js-sdk/pull/1020#discussion_r1777829664)
I've added a lint rule to enforce `import type`, and some additional
package changes to add a `lint:fix`.

The only changes I made manually here is to add the lint rule, and the
package.json script. All the changes are auto-generated by the
`lint:fix`.

---------

Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2024-10-16 14:33:47 -04:00
OpenFeature Bot 290184b04f
chore(main): release server-sdk 1.15.1 (#983)
🤖 I have created a release *beep* *boop*
---


##
[1.15.1](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.15.0...server-sdk-v1.15.1)
(2024-08-28)


### 🧹 Chore

* add assertion for hook context contents
([#977](https://github.com/open-feature/js-sdk/issues/977))
([964d65b](964d65b775))
* **main:** release core 1.4.0
([#984](https://github.com/open-feature/js-sdk/issues/984))
([01344b2](01344b28c1))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
2024-08-28 08:49:22 -04:00
OpenFeature Bot 01344b28c1
chore(main): release core 1.4.0 (#984)
🤖 I have created a release *beep* *boop*
---


##
[1.4.0](https://github.com/open-feature/js-sdk/compare/core-v1.3.0...core-v1.4.0)
(2024-08-28)


###  New Features

* updated the Metadata type to allow for custom properties
([#975](https://github.com/open-feature/js-sdk/issues/975))
([16b0d74](16b0d74340))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
Co-authored-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
2024-08-28 08:44:37 -04:00
Todd Baert 964d65b775
chore: add assertion for hook context contents (#977)
There's no bug here, but this adds some asserts for a tricky bug I
recently found in the Java SDK:
https://github.com/open-feature/java-sdk/pull/1049

Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2024-08-23 11:23:54 -04:00
OpenFeature Bot a3a9b22bef
chore(main): release server-sdk 1.15.0 (#959)
🤖 I have created a release *beep* *boop*
---


##
[1.15.0](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.14.0...server-sdk-v1.15.0)
(2024-06-11)


###  New Features

* lower compilation target to es2015
([#957](https://github.com/open-feature/js-sdk/issues/957))
([c2d6c17](c2d6c1761a))


### 🧹 Chore

* **main:** release core 1.3.0
([#958](https://github.com/open-feature/js-sdk/issues/958))
([25086c5](25086c5456))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
2024-06-11 10:50:06 -04:00
OpenFeature Bot 25086c5456
chore(main): release core 1.3.0 (#958)
🤖 I have created a release *beep* *boop*
---


##
[1.3.0](https://github.com/open-feature/js-sdk/compare/core-v1.2.0...core-v1.3.0)
(2024-06-11)


###  New Features

* lower compilation target to es2015
([#957](https://github.com/open-feature/js-sdk/issues/957))
([c2d6c17](c2d6c1761a))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
Co-authored-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
2024-06-11 13:21:30 +00:00
Michael Beemer c2d6c1761a
feat: lower compilation target to es2015 (#957)
## This PR

- replace the es2022 error cause with a custom implementation
- lower compilation target from es2022 to es2015

### Related Issues

Fixes #956

### Notes

The tests pass, but I still want to manually build and test the outputs
in a real application to ensure everything works as expected.

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-06-11 12:47:19 +00:00
OpenFeature Bot f2ebd11072
chore(main): release server-sdk 1.14.0 (#930)
🤖 I have created a release *beep* *boop*
---


##
[1.14.0](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.13.5...server-sdk-v1.14.0)
(2024-05-13)


### 🐛 Bug Fixes

* remove export of OpenFeatureClient
([#794](https://github.com/open-feature/js-sdk/issues/794))
([3d197f2](3d197f2ea7))
* removes exports of OpenFeatureClient class and makes event props
readonly ([#918](https://github.com/open-feature/js-sdk/issues/918))
([e9a25c2](e9a25c21cb))
* run error hook when provider returns reason error or error code
([#926](https://github.com/open-feature/js-sdk/issues/926))
([c6d0b5d](c6d0b5da9c))


### 🧹 Chore

* remove node 16
([#875](https://github.com/open-feature/js-sdk/issues/875))
([c1878e4](c1878e4eff))
* **main:** release core 1.2.0
([#927](https://github.com/open-feature/js-sdk/issues/927))
([692ad5b](692ad5b27a))


### 📚 Documentation

* add tip about supported usage in the install section
([#941](https://github.com/open-feature/js-sdk/issues/941))
([f0de667](f0de66770b))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-05-13 16:23:24 -04:00
OpenFeature Bot 692ad5b27a
chore(main): release core 1.2.0 (#927)
🤖 I have created a release *beep* *boop*
---


##
[1.2.0](https://github.com/open-feature/js-sdk/compare/core-v1.1.0...core-v1.2.0)
(2024-05-13)


###  New Features

* set context during provider init on web
([#919](https://github.com/open-feature/js-sdk/issues/919))
([7e6c1c6](7e6c1c6e70))


### 🐛 Bug Fixes

* removes exports of OpenFeatureClient class and makes event props
readonly ([#918](https://github.com/open-feature/js-sdk/issues/918))
([e9a25c2](e9a25c21cb))
* run error hook when provider returns reason error or error code
([#926](https://github.com/open-feature/js-sdk/issues/926))
([c6d0b5d](c6d0b5da9c))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
Co-authored-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-05-13 19:41:23 +00:00
Lukas Reining c1878e4eff
feat: remove node 16 (#875)
<!-- Please use this template for your pull request. -->
<!-- Please use the sections that you need and delete other sections -->

## This PR
<!-- add the description of the PR here -->

Removes Node 16 as it is deprecated.

Signed-off-by: Lukas Reining <lukas.reining@codecentric.de>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-05-13 14:52:47 -04:00
Lukas Reining 3d197f2ea7
fix: remove export of OpenFeatureClient (#794)
<!-- Please use this template for your pull request. -->
<!-- Please use the sections that you need and delete other sections -->

## This PR
As discussed here
https://github.com/open-feature/js-sdk/pull/750#discussion_r1450896230,
we should not export `OpenFeatureClient` from the server and web SDK.
The type used outside the SDK should be `Client`, which is also used in
the public APIs like `OpenFeatureApi`.

The question is, if we should mark this as breaking. 
Technically it will break code that imports `OpenFeatureClient` instead
of `Client`, but as @toddbaert said code using it could also be seen as
"used wrong" while being technically fine.

I am still leaning towards marking it as breaking, to be sure we are not
breaking something that is technically fine, just because it is
unintended use. But I could also live with non-beaking.

---------

Signed-off-by: Lukas Reining <lukas.reining@codecentric.de>
2024-05-08 20:41:03 +00:00
Michael Beemer 7e6c1c6e70
feat: set context during provider init on web (#919)
## This PR

- overloads the set provider methods to support defining context in the
web SDK
- updates the web sdk readme

## Related Issues

Fixes https://github.com/open-feature/js-sdk/issues/748

## Notes

I decided to only support setting context in the web SDK because it is
less valuable on the server and the expected behavior was less clear due
to `domains`.

The behavior may need to be spec'd out. An issue in the spec repo has
been created.
https://github.com/open-feature/spec/issues/219

---------

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-05-08 17:42:34 +00:00
Michael Beemer c6d0b5da9c
fix: run error hook when provider returns reason error or error code (#926)
## This PR

- runs error hook when provider returns reason error or error code

### Related Issues

Fixes #925

### Notes

Based on a conversation in Slack:
https://cloud-native.slack.com/archives/C06E4DE6S07/p1714581197391509

---------

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-05-08 17:38:04 +00:00
Michael Beemer f0de66770b
docs: add tip about supported usage in the install section (#941)
## This PR

- adds tip to node.js about web
- adds tip to web about node.js

### Notes

Related to the PR opened by @dabeeeenster.

https://github.com/open-feature/openfeature.dev/pull/552

---------

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-05-07 20:45:51 +00:00
Lukas Reining e9a25c21cb
fix: removes exports of OpenFeatureClient class and makes event props readonly (#918)
<!-- Please use this template for your pull request. -->
<!-- Please use the sections that you need and delete other sections -->

## This PR
<!-- add the description of the PR here -->

Removes OpenFeatureClient class from exports and makes event details
readonly as described here:
https://github.com/open-feature/js-sdk/issues/799

Signed-off-by: Lukas Reining <lukas.reining@codecentric.de>
2024-05-02 14:36:32 +00:00
OpenFeature Bot 8dd1eb7413
chore(main): release server-sdk 1.13.5 (#913)
🤖 I have created a release *beep* *boop*
---


##
[1.13.5](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.13.4...server-sdk-v1.13.5)
(2024-04-18)


### 🧹 Chore

* bump spec version badge to v0.8.0
([#910](https://github.com/open-feature/js-sdk/issues/910))
([a7b2c4b](a7b2c4bca0))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
2024-04-18 15:54:18 +00:00
Michael Beemer a7b2c4bca0
chore: bump spec version badge to v0.8.0 (#910)
## This PR

- bump spec version badge to v0.8.0

### Notes

The SDKs have been complimented with the latest spec release, but we
neglected to bump the badge version.

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-04-18 15:31:45 +00:00
OpenFeature Bot bca0ef2939
chore(main): release server-sdk 1.13.4 (#888)
🤖 I have created a release *beep* *boop*
---


##
[1.13.4](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.13.3...server-sdk-v1.13.4)
(2024-04-02)


### 🐛 Bug Fixes

* return metadata for the bound provider in hookContext
([#883](https://github.com/open-feature/js-sdk/issues/883))
([fd84025](fd84025bdf))


### 🧹 Chore

* **main:** release core 1.1.0
([#899](https://github.com/open-feature/js-sdk/issues/899))
([b3e5f7e](b3e5f7eb2a))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-04-02 18:47:01 +00:00
OpenFeature Bot b3e5f7eb2a
chore(main): release core 1.1.0 (#899)
🤖 I have created a release *beep* *boop*
---


##
[1.1.0](https://github.com/open-feature/js-sdk/compare/core-v1.0.0...core-v1.1.0)
(2024-04-02)


###  New Features

* add STALE pre-defined reason
([#898](https://github.com/open-feature/js-sdk/issues/898))
([7f4f080](7f4f0808a6))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
Co-authored-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
2024-04-02 14:31:27 -04:00
Federico Bond fd84025bdf
fix: return metadata for the bound provider in hookContext (#883)
Clients were incorrectly populating the hook context provider metadata
field with metadata from the default provider instead of the one bound
to the client.

Signed-off-by: Federico Bond <federicobond@gmail.com>
2024-03-26 11:11:33 +00:00
OpenFeature Bot fc4867799d
chore(main): release server-sdk 1.13.3 (#878)
🤖 I have created a release *beep* *boop*
---


##
[1.13.3](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.13.2...server-sdk-v1.13.3)
(2024-03-25)


### 📚 Documentation

* add peer dep explainer
([#876](https://github.com/open-feature/js-sdk/issues/876))
([cfd23b9](cfd23b90f0))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-03-25 15:28:27 -04:00
Todd Baert cfd23b90f0
docs: add peer dep explainer (#876)
Adds a blurb out peer deps and lib development, installation.

@beeme1mr I also added a bit about `--legacy-peer-deps` after the
closure of https://github.com/open-feature/js-sdk/issues/834

---------

Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
2024-03-15 13:57:04 +00:00
OpenFeature Bot 80a6465b58
chore(main): release server-sdk 1.13.2 (#862)
🤖 I have created a release *beep* *boop*
---


##
[1.13.2](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.13.1...server-sdk-v1.13.2)
(2024-03-12)


### 🧹 Chore

* **main:** release core 1.0.0
([#869](https://github.com/open-feature/js-sdk/issues/869))
([4191a02](4191a02dbc))


### 📚 Documentation

* fixed feature table formatting
([84a26db](84a26db427))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
2024-03-12 14:58:15 -04:00
OpenFeature Bot 4191a02dbc
chore(main): release core 1.0.0 (#869)
🤖 I have created a release *beep* *boop*
---


##
[1.0.0](https://github.com/open-feature/js-sdk/compare/core-v0.0.28...core-v1.0.0)
(2024-03-12)


### 🧹 Chore

* release core as 1.0.0
([d06b285](d06b285cc3))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
Co-authored-by: openfeature-peer-update-bot <openfeature-peer-update-bot@openfeature.dev>
2024-03-12 14:55:15 -04:00
Michael Beemer 84a26db427
docs: fixed feature table formatting
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
2024-03-11 15:46:25 -04:00
OpenFeature Bot ac42a7e48e
chore(main): release server-sdk 1.13.1 (#851)
🤖 I have created a release *beep* *boop*
---


##
[1.13.1](https://github.com/open-feature/js-sdk/compare/server-sdk-v1.13.0...server-sdk-v1.13.1)
(2024-03-05)


### 🧹 Chore

* **main:** release core 0.0.28
([#849](https://github.com/open-feature/js-sdk/issues/849))
([31b92a9](31b92a97c1))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
2024-03-05 18:09:14 -05:00