Provider Setup

To use Grunfeld, you first need to set up the GrunfeldProvider at the top level of your application. This Provider is responsible for rendering and managing the state of dialogs.

Next.js App Router#

If you're using Next.js App Router, add the Provider to your layout file:

Next.js Pages Router#

If you're using Pages Router, add the Provider to your _app.tsx file:

React (Vite, CRA)#

In a regular React application, add the Provider to your app's root component:

Provider Setup - Configuring Grunfeld Provider | ilokesto - React Library Collection