Quickstart React
This quickstart guide uses our React SDK to embed a native integration hub into your application. More information on the React SDK, and other lower-level SDKs Versori provides, can be found in the versori/versori-js-sdk repository.
The React SDK is the quickest way to get started with Versori Embedded, however it also offers the least amount of control over the UI.
If your UI has more bespoke requirements, it’s recommended to learn more about how Versori Embedded works and then follow the Developers Introduction to choose the best implementation method for your application.
Disclaimer
There are limitations in this approach at the time of writing, but we are working on improving this functionality in future releases:
- Only the first page of integrations are displayed
- Connection Variables are not supported
- Integration Variables are not supported
Before you start, it’s expected that you already have a React application. If not, we recommend using Vite to quickly scaffold a new project.
Next, install our SDK packages using your package manager of choice:
Now you can render our VersoriEmbeddedProvider
component in your application, and pass in some configuration:
This example is the most minimal setup required to get started. The VersoriEmbeddedProvider
component configures an
EmbedClient
instance and exposes it over a React context. The VersoriEmbeddedRenderer
component is a pre-built
component which renders the integration hub UI in your application, handling displaying the correct UI elements based on
whether the End User has the integrations activated.
Given the above, the VersoriEmbeddedRenderer
is optional, and you can build your own UI components consuming the
EmbedClient
context directly if this suits your application better.
For more information on using the SDK, the source code is available in the versori/versori-js-sdk repository.