Skip to content

Commit 5e95a31

Browse files
committed
display data with the "debug" component by default
1 parent fa5aef6 commit 5e95a31

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@
2323
This allows using more database-specific features in SQLPage and avoids confusion.
2424
- Create a single database connection by default when using `sqlite://:memory:` as the database URL.
2525
This makes it easier to use temporary tables and other connection-specific features.
26+
- When no component is selected, display data with the `debug` component by default.
27+
This makes any simple `SELECT` statement a valid SQLPage file.
28+
Before, data returned outside of a component would be ignored.
2629

2730
## 0.9.5 (2023-08-12)
2831

src/render.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,7 @@ impl<W: std::io::Write> RenderContext<W> {
278278

279279
if let Some(component) = initial_component {
280280
log::trace!("The page starts with a component without a shell: {component}");
281+
initial_context.open_component(component).await?;
281282
initial_context.handle_row(&initial_row).await?;
282283
}
283284

0 commit comments

Comments
 (0)