I have added an example that can now be done with SQLite and the async component generators of Brisa
import { Database } from "bun:sqlite";
const db = new Database("db.sqlite");
export default function MovieList() {
return (
<ul>
<MovieItems />
</ul>
);
}
// Streaming HTML from SQLite query
async function* MovieItems() {
for (const movie of db.query("SELECT title, year FROM movies")) {
yield (
<li>
{movie.title} ({movie.year})
</li>
);
}
}
I have added an example that can now be done with SQLite and the async component generators of Brisa