fix(replay): fixed type for options of replayIntegration#10325
Merged
mydea merged 1 commit intogetsentry:developfrom Jan 24, 2024
Merged
fix(replay): fixed type for options of replayIntegration#10325mydea merged 1 commit intogetsentry:developfrom
mydea merged 1 commit intogetsentry:developfrom
Conversation
billyvg
reviewed
Jan 24, 2024
| Partial<Pick<ReplayPluginOptions, 'sessionSampleRate' | 'errorSampleRate'>>; | ||
|
|
||
| export const replayIntegration = ((options?: InitialReplayPluginOptions) => { | ||
| export const replayIntegration = ((options?: ReplayConfiguration) => { |
Member
There was a problem hiding this comment.
We'll want the options type to be
Omit<ReplayPluginOptions, 'sessionSampleRate' | 'errorSampleRate'>
because these sample rate options are deprecated and slated to be removed, can you confirm @mydea?
Contributor
Author
There was a problem hiding this comment.
Ok then, In that case i guess it should be wrapped with Partial then.
Because the options are required in ReplayPluginOptions type. Causing the error mentioned.
Member
There was a problem hiding this comment.
@Shubhdeep12 Ah my mistake, it should be Omit<ReplayConfiguration, 'sessionSampleRate' | 'errorSampleRate'>
Member
There was a problem hiding this comment.
So I think ReplayConfiguration is correct for now, we can remove the deprecated fields in a follow up in v8!
Member
|
Thank you! |
mydea
approved these changes
Jan 24, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Before submitting a pull request, please take a look at our
Contributing guidelines and verify:
yarn lint) & (yarn test).fixes: Unable to override only a few options for
replayIntegration#10305