Skip to content

docs: evaluate Browser bootstrap per request and fix the Node offline default - #853

Merged
roncohen merged 2 commits into
mainfrom
docs/readme-review-followup
Dec 1, 2026
Merged

roncohen merged 2 commits into
mainfrom
docs/readme-review-followup

Conversation

@roncohen

@roncohen roncohen commented Dec 1, 2026 •

Copy link
Copy Markdown
Contributor

Follow-up to #852. These two review fixes were ready after #852 entered the merge queue, so they missed it.

  • Browser README bootstrap example: it called getFlagsForBootstrap() once at server startup and served that snapshot on every request. Bootstrapped clients skip their initial fetch, so flag changes didn't reach pages until the server restarted. The example now evaluates flags inside the request handler and keeps the shared Node client.
  • Node README offline option: it said offline mode defaults to true based on a TEST environment variable. The SDK actually checks NODE_ENV === "test" (client.ts), so the description now says that.
  • Browser README script tag: it loaded cdn.jsdelivr.net/npm/@reflag/browser-sdk@2, a major-pinned URL carried over from v1. The docs check keeps major-pinned installs out of the SDK pages and in the upgrade guide, so the example now loads @reflag/browser-sdk without a version.

@roncohen
roncohen enabled auto-merge December 1, 2026 09:28

@reflag-review reflag-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Risk: low

no actionable findings

@roncohen
roncohen added this pull request to the merge queue Dec 1, 2026

@reflag-review reflag-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Risk: low

no actionable findings

Merged via the queue into main with commit 3906e4f Dec 1, 2026
6 checks passed
@roncohen
roncohen deleted the docs/readme-review-followup branch December 1, 2026 09:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant