Home

Awesome

React Server Components Demo

This is a fork of the original demo without the Postgres dependency

What is this?

This is a demo app built with Server Components, an experimental React feature. We strongly recommend watching our talk introducing Server Components before exploring this demo. The talk includes a walkthrough of the demo code and highlights key points of how Server Components work and what features they provide.

When will I be able to use this?

Server Components are an experimental feature and are not ready for adoption. For now, we recommend experimenting w Server Components via this demo app. Use this in your own projects at your own risk.

Setup

npm install
npm start

(Or npm run start:prod for a production build.)

Then open http://localhost:4000.

The app won't work until you set up the database, as described below.

DB Setup

There is no database in this fork.

I replaced it with an object in ./src/db.server.js.

Notes about this app

The demo is a note taking app called React Notes. It consists of a few major parts:

This demo is built on top of our Webpack plugin, but this is not how we envision using Server Components when they are stable. They are intended to be used in a framework that supports server rendering — for example, in Next.js. This is an early demo -- the real integration will be developed in the coming months. Learn more in the announcement post.

Interesting things to try

Built by (A-Z)

Code of Conduct

Facebook has adopted a Code of Conduct that we expect project participants to adhere to. Please read the full text so that you can understand what actions will and will not be tolerated.

License

This demo is MIT licensed.