Embed a Shaper dashboard into a React Router app using the Shaper React SDK
See the index route for how to use the ShaperDashboard component.
The demo uses a fetcher load a JWT.
See the /jwt route for how to create a JWT using the Shaper API.
Make sure to never expose the API_KEY in the client code.
In a real application, you would need to make sure the user is allowed to see the specified dashboard and set variables based on the user's permissions.
Install the dependencies:
npm installMake sure you have Docker installed and running. Then, start the Shaper server:
npm run shaperThe demo database is included in the Git repository and it should work automatically.
You can visit the Shaper UI at http://localhost:5454
Start the development server:
npm run devThen open http://localhost:5173