Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rafaelrcamargo/r19
A dead-simple React 19 "framework" implementation from scratch
https://github.com/rafaelrcamargo/r19
bun esm react rsc
Last synced: about 5 hours ago
JSON representation
A dead-simple React 19 "framework" implementation from scratch
- Host: GitHub
- URL: https://github.com/rafaelrcamargo/r19
- Owner: rafaelrcamargo
- Created: 2024-01-27T13:50:14.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2024-11-06T02:19:28.000Z (3 months ago)
- Last Synced: 2025-01-15T07:00:23.452Z (7 days ago)
- Topics: bun, esm, react, rsc
- Language: TypeScript
- Homepage: https://cmrg.me/blog/rsc-part-1-the-backstory
- Size: 2.99 MB
- Stars: 79
- Watchers: 1
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: docs/README.md
Awesome Lists containing this project
README
# R19 🏎️
A React 19 "framework" **from scratch**.
> The name was definitely not inspired by F1 cars. :))
## Features
This has a lot of cool caveats, like using Bun for most of the internals and _(maybe)_ the first React 19 framework to implement ESM and not a bundler like Webpack to be bundled.
- [x] Bundling
- [x] TS Support
- [x] JSX Support
- [x] Assets (Images, Styles, etc...)
- [x] File-based routing
- [x] RSC (React Server Components)
- [x] RSF (React Server Functions)
- [x] SSR
- [x] Static export *(with `export const dynamic = "force-dynamic"` to opt-out)*
- [x] Serve static files for default route states## Examples
- [x] Simple
- A basic overview of the features
- [x] Advanced
- A more complex system with a SQLite database## Usage
This project uses `react-server-dom-esm` as the "plugin" to integrate with most of the React 19 features. But this package is not published yet, so you need to clone the `react` repo and build it yourself.
```bash
git clone https://github.com/facebook/react.git
cd react
yarn && yarn build
```Then, the `predev` script will copy the necessary files to the `node_modules` folder. _(It expects the `react` repo to be in the same parent directory as this repo.)_
With all the dependencies set up, you can run the project with:
```bash
bun i
bun dev
```## License
I don't encourage anyone to use this project in production, **not even close to it**. This is just a fun project where all can learn more about React and its internals.