DevCycle Next.js SDK
The DevCycle Next.js SDK lets you easily integrate your Next.js applications with DevCycle.
Installation
Installing the SDK
Usage - App Router
Initializing the SDK
Usage - Pages Router
Initializing the SDK
Typescript
SDK features for Typescript users
Example App
Try it out for yourself
The SDK is available as a package on npm. It is also open source and can be viewed on Github. This SDK depends on the fetch API.
Features
- full support for App Router and server components
- keep server and client rendered content in sync with the same variable values
- realtime updates to variable values for both server and client components
- support for Suspense streaming rendering with non-blocking variable state retrieval
- support for static page rendering
- exclude component code from client bundle when feature is disabled
Requirements
| SDK Version | Minimum Next.js Version | Minimum React Version |
|---|---|---|
| 3.0.0+ | 15.1.0 | 18.2 |
| 2.0.0+ | 14.1.0 | 18.2 |