There are many great tools for building websites with JavaScript. Jeasx deliberately does less than most of them: it renders JSX on the server, bundles your browser assets with esbuild and gets out of your way. This page shows where Jeasx differs from popular alternatives, so you can pick the right tool for your project.

Overview

JeasxAstroNext.jsFresh
RenderingServer-side on every requestStatic by default, server optionalStatic, server and clientServer-side on every request
TemplatesPlain JSX (or MDX)

.astro files with frontmatter

React componentsPreact components
Client-side JavaScriptOnly what you writeIslands of UI frameworksReact runtime & hydrationIslands with Preact
Async componentsYes, everywhereYes, in frontmatterServer Components onlyYes, in routes
RuntimeNode.js (Fastify)Node.js & adaptersNode.js & Vercel-orientedDeno
Build toolesbuildViteTurbopackVite
Special IDE support neededNoYes (Astro plugin)NoNo

Jeasx vs. Astro

Astro is a great choice for content-driven websites and shares a lot of ideas with Jeasx: HTML first, as little JavaScript as possible in the browser. The main differences:

  • Syntax: Astro uses its own file format with a code block separated by --- and a JSX-like template. It requires a dedicated compiler and an IDE plugin. Jeasx uses plain JSX, so your editor, TypeScript and formatter work out of the box.
  • Static vs. dynamic: Astro generates static pages by default and needs an adapter for server-side rendering. Jeasx always renders on the server, which makes dynamic content (e.g. from a database or headless CMS) the default instead of the exception.
  • Islands: Astro can hydrate React, Vue, Svelte or Solid components in the browser. Jeasx doesn't ship a client framework, but you can add whatever you like (htmx, Alpine.js, Web Components or even React) via the browser bundle.
  • Scope: Astro includes content collections, image optimization, view transitions and a rich integration ecosystem. Jeasx keeps the core small and leaves these decisions to userland.

Jeasx vs. Next.js

Next.js is a full-stack React framework. With React Server Components it moved towards server-side rendering, but it still ships the React runtime to the browser and mixes server and client code in one component tree.

  • Jeasx has no hydration, no client/server boundary ("use client") and no hydration errors.
  • Jeasx components are just async functions returning strings, without hooks or a virtual DOM.
  • Jeasx has no complex caching layers: a request is rendered, the response is sent. Caching is up to you (e.g. via HTTP headers or a reverse proxy).
  • Next.js has a huge ecosystem and is a better fit for highly interactive, app-like user interfaces.

Jeasx vs. Fresh

Fresh renders Preact on the server and hydrates islands in the browser. It is conceptually close to Jeasx, but relies on Deno, which may not fit your corporate policies or hosting environment. Jeasx runs on plain Node.js and the npm ecosystem.

Jeasx vs. template engines

Classic template engines like EJS, Handlebars, Pug or Nunjucks (often used with Express or Fastify) render HTML on the server as well. Jeasx replaces their custom template languages with JSX:

  • Components are JavaScript functions, so you can use imports, types and refactoring tools.
  • Routing, bundling of CSS & JavaScript and hot reloading are already set up for you.

Jeasx with htmx & Alpine.js

htmx and Alpine.js are not alternatives, but perfect companions for Jeasx. Jeasx renders HTML fragments on the server, htmx swaps them into the page, and Alpine.js adds small bits of interactivity. Together they cover many use cases of single page applications with a fraction of the complexity.

When to choose Jeasx

Jeasx is a good fit if you want to:

  • render dynamic content on the server, e.g. from a database or headless CMS,
  • use JSX without React, hydration or a client-side runtime,
  • stay on Node.js with a small, stable set of dependencies,
  • keep full control over your architecture instead of following framework conventions.

Consider another framework if you need a purely static site with many built-in integrations (Astro), a highly interactive app-like user interface (Next.js), or prefer the Deno ecosystem (Fresh).

The right tool for the job

All of these frameworks are great products. Jeasx focuses on a small, stable core and lets you build everything else in userland: if your code works, it just works.