Skip to content

Commit

Permalink
DocGen 24_1 result (#6731)
Browse files Browse the repository at this point in the history
  • Loading branch information
dxrobot authored Oct 21, 2024
1 parent ac73eea commit 324a759
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ The first `import` allows you to use the DataGrid component. The second applies

### Set up a Data Source

[note] If you use [DataSource](/Documentation/ApiReference/Data_Layer/DataSource/), add a [`use client` directive](https://nextjs.org/docs/app/building-your-application/rendering/client-components#using-client-components-in-nextjs) to ensure that the instance is created on the client only. DataSource instances do not support React serialization and therefore cannot be created on the server and sent to the client.
[note] If you use [DataSource](/api-reference/30%20Data%20Layer/DataSource '/Documentation/ApiReference/Data_Layer/DataSource/'), add a [`use client` directive](https://nextjs.org/docs/app/building-your-application/rendering/client-components#using-client-components-in-nextjs) to ensure that the instance is created on the client only. DataSource instances do not support React serialization and therefore cannot be created on the server and sent to the client.

Our DataGrid requires a data source. For the purpose of this tutorial, we'll use data from the publicly available [Cat Facts API](https://catfact.ninja). Add the following asynchronous code to the `page.tsx` file:

Expand Down

0 comments on commit 324a759

Please sign in to comment.