Nitro

Examples

A blog, five ways

One small blog, built five times: with Blade, Vue, React, Solid and Svelte views. The PHP is the same each time; only the views change. Each one runs live on its page.

On this page

Each blog has a form to write and edit posts, and a list to search, read and delete them. They are two components that talk through events, as the parts of a real app would. Every page shows its files in full, exactly as they run.

The posts are yours

The examples keep posts in your session, so you can write anything: no one else sees it, and it's gone when the session ends. Every page starts with the same few posts. A post you write on one page shows up on the others, since they share your session.

Everything you type is shown as text, never as HTML, in each framework: Blade's {{ }}, Vue's @{{ }}, React's, Solid's and Svelte's { } all escape it. The rules on the form are checked in the browser as you type, and again on the server, which is the check that counts.