rox-ssr in details
From a developer’s perspective, only rox-ssr is used. In the background, rox-ssr is automatically switching between rox-node and rox-browser depending on the environment. We know developers care about the size of their applications so we kept that in mind such that server-specific code is not bundled into your final client bundle. We successfully tested that with Webpack! We also know that developers care not only about the look and feel, but also performance. CloudBees Feature Management does not fetch flag values from its servers at every evaluation but instead fetches the flag configuration once and then uses it to evaluate the flags. Calling flag.isEnabled() is a local, constant-time operation. This was always true, rox-ssr makes it even better. On the server-side, rox-ssr will fetch that configuration and refresh it regularly. Rox-ssr allows you to directly pass this configuration to the browser, making the initialization of CloudBees Feature Management on the client side immediate: no delay due to fetching data from the CloudBees Feature Management server and no potentially annoying re-rendering of elements on the page due to flag configuration being received a few milliseconds too late. See this example below.
How to use rox-ssr
Register and create your new app on rollout.io
Initialize CloudBees Feature Management - this should be once on the server-side, once on the client-side
In your render() method, server-side, add a within the tag to send the CloudBees Feature Management configuration from the server to the clients:
Using the flags
How to migrate from rox-node and/or rox-browser to rox-ssr You might have had something like:
let Rox = null
Stay up to date
We'll never share your email address and you can opt out at any time, we promise.