-
Notifications
You must be signed in to change notification settings - Fork 83
Typescript - Breaking changes in 4.9.2 #811
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
FYI the solution to the first issue is typeof enums.LOG_LEVEL[keyof typeof enums.LOG_LEVEL] |
@philBrown - thanks for bringing this to our attention, will look into this. |
Looks like this was an unintentional breaking change on our end likely introduced in this PR #745 - will have an internal discussion on how we'll address the changes introduced in that PR going into our next release and reply here when we have any updates. |
Following up on this issue - we are currently prioritizing some features in development, however we plan on accounting for this issue through either a fix or officially addressing the type changes in a future update. In the meantime, please use the workaround for now. |
Internal Ticket Created: FSSDK-9569 |
This was an unintentional breaking change that was released as 4.9.2. There were several other releases of v4 after that with the same changes. Recently we released v5 of the sdk. This seems to be a good time to close this issue. Unfortunately, users only updating minor or patch version of v4 will still face the breaking change. |
What I wanted to do
Upgrade the Optimizely SDK from 4.9.1 to 4.9.2 without requiring any other code changes.
What I expected to happen
Given it's a patch release, it should just work.
What actually happened
Several breaking changes require updates to consuming code...
enums.LOG_LEVEL
changes fromenum
to an object literal. Can no longer useenums.LOG_LEVEL
in typings, egThe default export is no longer a namespace requiring the following change
createInstance()
now returnsClient | null
instead of justClient
Steps to reproduce
Change
"@optimizely/optimizely-sdk": "4.9.1",
to"@optimizely/optimizely-sdk": "4.9.2",
inpackage.json
and runtsc
.These changes should have been released as a major version bump, ie v5.0.0.
The text was updated successfully, but these errors were encountered: