5/10/2025
Modern site generators love the illusion of simplicity.
You drop a file into pages/blog/[slug].js and the framework smiles: “We’ve handled routing for you.” Until you want to localize it. Or paginate it. Or generate routes from dynamic data.
Then you're in abstraction hell — juggling folders, filenames, and undocumented behavior.
Rift doesn’t play that game.
In Rift, you define routes using two functions:
params(ctx) – tells Rift what data you want to renderpermalink(ctx) – tells Rift exactly what URL to use for each pageThat’s it. No guessing. No magic interpolation. No pretending that file structure is routing logic.
It works great for a five-page site. But try building a multilingual, paginated, tag-filtered blog with clean URLs using just filenames and folders. You’ll end up with:
It’s brittle, unreadable, and difficult to scale.
Want this?
/en/blog/javascript-is-awesome/
You write:
return `/${ctx.locale}/blog/${ctx.params.slug}/`
Simple. Obvious. Flexible.
If your data comes from an API, a DB, or a flat file — no problem.
In your controller, fetch it. Loop through it. Use ctx.param() to declare pages. Rift doesn’t care how you build the data — it just renders what you tell it to.
No restrictions. No "but only if it's in a folder."
You’re a developer. You don’t need a framework guessing what you meant. Rift gives you the tools to define your site’s structure like an engineer — not a magician.
npm create rift@latest
Within 30 seconds, you’ll be writing actual route logic — not naming files to hope they behave the way you want.
Rift is a zero-guesswork static site generator built for developers. Try it today:
npm create rift@latest