feat(browser): Add support for pre-loaded remote-config#3242
Draft
dustinbyrne wants to merge 2 commits intomainfrom
Draft
feat(browser): Add support for pre-loaded remote-config#3242dustinbyrne wants to merge 2 commits intomainfrom
dustinbyrne wants to merge 2 commits intomainfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
Contributor
|
Size Change: +3.78 kB (+0.06%) Total Size: 6.69 MB
ℹ️ View Unchanged
|
Contributor
|
This PR hasn't seen activity in a week! Should it be merged, closed, or further worked on? If you want to keep it open, post a comment or remove the |
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.
Problem
When using the upcoming snippet v2, the server provides version-pinned SDK assets via remote config. The browser SDK needs to support loading extensions (recorder, toolbar, etc.) from these versioned CDN paths instead of the default
/static/route.Changes
sdkVersionfield toRemoteConfigtype withrequested,resolved, and optionalscriptBaseUrlproperties_scriptBaseUrlproperty to PostHog core, set fromconfig.sdkVersion.scriptBaseUrlduring remote config processing$sdk_version_requestedas a session property when present_scriptBaseUrlis set, falling back to the existing/static/path for v1 snippet behaviorremote-configscripts always load from the token-specific path regardless of_scriptBaseUrlRelease info Sub-libraries affected
Libraries affected
Checklist
If releasing new changes
pnpm changesetto generate a changeset file