Open source · React 19 · Node.js 22, 24 & 26
React server rendering, without the framework.
Hoosat Create scaffolds a full-stack React and TypeScript app that streams HTML from a small, dependency-light Node.js server. No Express, no magic, just code you can read and own.
npx hoosat-create@latest$ npx hoosat-create@latest
Creating a new project from Hoosat React SSR Template.
Enter destination project name: my-site
Do you want to initialize a git repository? [Y/n] y
Project cloned successfully.
Project template dependencies installed with npm.
$ cd my-site && npm run dev
Server is running on port 8181- 1command to a running SSR app
- 0Express or Babel dependencies
- 3precompressed formats: br, gzip, deflate
- 100%TypeScript, build tools included
Measured on your visit
Fast is easy to claim, so here are the numbers. They are measured live in your browser for the page load that opened this site, from the Server-Timing header this server sends and the browser's own timing APIs.
- Server render
- …
- Routing the request to the first byte of streamed HTML
- First byte
- …
- From navigation start, network included
- First paint
- …
- First content on screen
- Interactive
- …
- React finished hydrating the server HTML
- Fully loaded
- …
- The load event finished
Client and server, kept apart
Many React frameworks fuse server and client code into the same files with server components, loaders and server actions, and decide at build time what runs where. In Hoosat Create, the folder decides.
src/clientBrowserYour React app: pages, components and CSS. Bundled for the browser, starting from src/client/index.tsx.
src/serverNode.jsYour own HTTP server: middlewares, API routes and rendering. Bundled into build/server.js, starting from src/server/index.tsx.
src/commonBothCode both sides import, like this site's language picker and settings. Nothing browser- or server-specific.
Two webpack configs, two bundles and no "use client" or "use server" directives. You always know what ships to the browser.
Everything a production site needs, nothing it doesn't
The template is a starting point you copy, not a framework you depend on. Every feature below is plain code in your repository.
Streaming SSR
Pages render with React 19's renderToPipeableStream, so the browser gets real HTML first and then hydrates it into an interactive app.
A router you can read
The server core is a few hundred lines of TypeScript on Node's http and https modules: middlewares, :params, wildcards and composable routers.
SEO in the first bytes
Titles, meta, Open Graph and JSON-LD written with react-helmet-async are streamed into the head, so crawlers see them without running JavaScript.
Precompressed assets
The build writes Brotli, gzip and deflate copies of every public file. The server picks one by Accept-Encoding and sets long cache headers.
TypeScript everywhere
Strict TypeScript 6 for client, server and shared code. Even the build tools are .ts files that Node runs directly with type stripping.
Built-in i18n
i18next and react-i18next are wired in on both sides. This site renders English or Finnish per request. Try the switch in the header.
Secure defaults
A Content-Security-Policy header with a nonce, path traversal safe static files, and an .npmrc that only installs packages public for 7 days.
Tests from day one
Jest 30 and Testing Library come configured, with example tests for the server core. Run npm test and npm run typecheck in CI.
Fast dev loop
npm run dev rebuilds the client and the server whenever you save and restarts the server with nodemon, so changes show up in seconds.
How a request becomes a page
One request through the stack, from socket to interactive page. Each step is a file you can open.
Request
Node's http or https server accepts the request, and the URL is sanitised against path traversal.
Middlewares
Middlewares run in order. On this site: robots.txt and sitemap.xml, then precompressed static files.
Routes
API routes such as /api/ping/:id answer directly. Everything else falls through to the * route.
React render
The * route picks the language, renders <App /> inside a StaticRouter and streams it to the client.
Head injection
A transform stream writes Helmet tags, preload links and the bundles into the head while the HTML streams out.
Hydration
In the browser hydrateRoot attaches React to the existing markup. From here on, navigation happens on the client.
Your server is just a file
src/server/index.tsx is the whole server. Middlewares and routes are plain functions. This is a trimmed version of the file that serves this page.
Current, boring, supported
Every dependency is on its latest major release, and the template is tested on all supported Node.js LTS lines.
- React19
- React Router8
- TypeScript6
- react-helmet-async3
- i18next27
- Webpack5
- Jest30
- Node.js22 · 24 · 26
import { createRouter, createServer, listen } from './core/server';
import { assets } from './core/assets';
import { renderer } from './core/renderer';
const router = createRouter();
// Middlewares run in order, before any route.
router.Middleware(seoFiles());
router.Middleware(assets(publicDir));
// API routes answer directly.
router.UseRouter(APIRouter);
// Every other GET request is a React page.
router.Get("*", async (req, res) => {
const lng = pickLanguage(req.headers.cookie, req.headers['accept-language']);
if (isNotFound(req.url)) res.status(404);
renderer({ res, jsx: <Document url={req.url} lng={lng} />, publicDir });
});
listen(createServer(router), 8181, () => console.log("Ready"));Talk to the server
This button calls the /api/ping route from src/server/api-routes. The page itself was rendered on the server: turn JavaScript off and reload, it still reads the same.
Start your next site in one command
Run the command, answer a few questions and open http://localhost:8181. The tutorial walks you through the rest.
npx hoosat-create@latest