https://github.com/irekrog/rsc-server-data
Get and show data from the server
https://github.com/irekrog/rsc-server-data
next nextjs react react-server-components reactjs rsc
Last synced: 8 months ago
JSON representation
Get and show data from the server
- Host: GitHub
- URL: https://github.com/irekrog/rsc-server-data
- Owner: irekrog
- License: mit
- Created: 2023-03-12T10:33:31.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2023-03-12T11:35:38.000Z (almost 3 years ago)
- Last Synced: 2025-02-11T12:52:47.565Z (10 months ago)
- Topics: next, nextjs, react, react-server-components, reactjs, rsc
- Language: TypeScript
- Homepage: https://rsc-server-data-example.vercel.app/rsc-server-data
- Size: 19.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# rsc-server-data
Get and show data from the server.
## DON'T USE THIS IN PRODUCTION
## Requirements
This is a [React Server Component (RSC)](https://beta.nextjs.org/docs/rendering/server-and-client-components#server-components) and works with [Next.js with App Router](https://beta.nextjs.org/docs/app-directory-roadmap).
## Getting Started
```bash
npm install rsc-server-data
```
or
```bash
yarn add rsc-server-data
```
or
```bash
pnpm add rsc-server-data
```
## Usage
```tsx
import { ServerData } from "rsc-server-data";
const App = () => {
return ;
};
```
## Example
https://github.com/irekrog/rsc-server-data-example
https://rsc-server-data-example.vercel.app/rsc-server-data