Skip to content
NexyPyPublic

About

Un framework Python conçu pour allier simplicité, performance et plaisir du développement.

Resources

Code of conduct

Contributing

Security policy

Stars

7 stars

Watchers

1 watching

Forks

Latest commit

 

History

135 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nexy

Nexy

The fullstack Python meta-framework — sub-second startup, sub-100ms HMR

PyPI version Python versions GitHub stars License Last commit


Why Nexy?

Most Python web frameworks force you to choose: backend or frontend. Nexy is the first Python meta-framework that seamlessly bridges FastAPI with Vite-powered frontends (React, Vue, Svelte, Solid) — without sacrificing DX or performance.

You get Instead of
Sub-second startup Waiting 10-30s for Next.js/Rails
One .nexy file = backend + frontend Separate projects for API + UI
Zero-config Vite integration Manually wiring Webpack/Vite
Framework-agnostic UI Being locked into one JS framework
SSR + SSG out of the box Adding SSG as an afterthought

Quick start

# Create a project — no pip install needed
uvx nexy new

# Start developing
cd my-project && nexy dev

That's it. Your browser opens at http://localhost:3000 with HMR, FastAPI backend, and Vite frontend — all hot-reloading on save.

Code example

One .nexy file. Server-rendered HTML + interactive frontend component.

---
title : prop[str] = "Dashboard"
from "@/components/Chart.tsx" import Chart
---

<h1>{{ title }}</h1>

<Chart data="{{ api_data }}" />

The --- block is Python: declare props, import components. Below is Jinja2: server-rendered HTML. Frontend frameworks hydrate on top via Vite.

Features

.nexy — polyglot components

A single file format that mixes Python, Jinja2, and your UI framework of choice.

┌─────────────────────┐
│  ---                │  ← Python logic (props, imports)
│  title : prop[str]  │
│  ---                │
│  <h1>{{ title }}</h1>│  ← Jinja2 template (SSR)
│  <Chart />           │  ← TS/JS client island
└─────────────────────┘

Dual routing — scale with your project

  • File-based: src/routes/index.nexy → /, src/routes/blog/[slug].nexy → /blog/{slug}
  • Modular: NestJS-inspired decorator-based routing for enterprise apps
  • Hybrid: Mix static pages and dynamic API routes in the same project

Framework-agnostic frontend

Import React, Vue, Svelte, Solid, or Preact components directly into your .nexy templates. No adapter, no bridge, no configuration.

# Works in any .nexy file
from "@/components/Chart.tsx" import Chart     # React/Solid/Preact
from "@/components/Table.vue" import Table     # Vue
from "@/components/Card.svelte" import Card    # Svelte

Production-grade SSR & SSG

  • SSR: Server-side rendering for every component (esbuild per-file, no Vite dependency)
  • SSG: Parallel static generation with worker pool
  • Automatic: Framework detection from imports, zero config

CLI — one tool to rule them all

Command Purpose
nexy new Scaffold a new project
nexy dev Dev server with HMR
nexy build Production build
nexy start Production server

Architecture at a glance

graph TD
    A[Browser] --> B[Uvicorn / FastAPI]
    B --> C{AppServer}
    C --> D[Router: FBR or Modular]
    C --> E[VFS: Virtual File System]
    C --> F[Vite: HMR & Bundles]
    D --> G[.nexy Compiler]
    G --> H[Parser] --> I[AST] --> J[Jinja2] --> K[HTML]
    E --> L[Module Finder/Loader]
    F --> M[Frontend Frameworks]
    N[Watcher] --> O[FS Events]
    O --> P[compile + restart]
Loading

Supported frontend frameworks

Framework Status SSR SSG HMR
React Stable ✓ ✓ ✓
Vue Stable ✓ ✓ ✓
Svelte Stable ✓ ✓ ✓
Solid Stable ✓ ✓ ✓
Preact Stable ✓ ✓ ✓
None (vanilla) Stable ✓ — ✓

Project status

Nexy is in active development. The core features are stable and production-ready. We welcome contributions of all kinds — bug reports, feature requests, and pull requests.

See CONTRIBUTING.md to get started, or browse good first issues.

Community

License

Nexy is open-source software licensed under the MIT License.

About

Un framework Python conçu pour allier simplicité, performance et plaisir du développement.

Resources

Code of conduct

Contributing

Security policy

Stars

7 stars

Watchers

1 watching

Forks

Releases

Sponsor this project

Packages

Contributors

Languages