Nexanexa
Step 17

Going to production

The final stretch: lint, test, and a real deploy — the same path this very site followed, published on GitHub Pages.

nexa lint

nexa lint
# [NEXA-SEO-001] missing `title` in `seo`
# Error: `nexa lint` found warnings

Compiles every page without writing dist/ and fails if the SEO Analyzer or package warnings found anything — meant to block a merge in CI.

nexa test

nexa test
# Compiling the project before running tests...
# Running `npm test`...

Compiles the project (a fresh dist/, with the Fase 23 hashed filenames) and runs the project's JS test runner against that build.

nexa add nginx

nexa add nginx
# Generates deploy/nginx.conf — gzip, security headers,
# a year-long immutable cache only for hashed files.

Generates a real deploy/nginx.conf: gzip, security headers, and a year-long immutable cache only for the files that genuinely carry a content hash.

Dynamic routes with no paths, in real production

location /articles/ {
    proxy_pass http://127.0.0.1:4321;
    proxy_set_header Host $host;
}
# nexa preview running behind it, serving that route on the fly

A route that doesn't declare paths (its parameter space can't be enumerated upfront) still can't be pre-rendered — but nexa add nginx also generates a real proxy_pass towards a nexa preview running behind it, tested end to end against a real backend: not "run the dev server in prod", a documented and verified mechanism.

Done

dist/ is 100% static — any host serves it. This complete tutorial ends here: you now have what it takes to take a real Nexa project to production.