leptos/examples/hackernews
martin frances 69d25d9c63
examples/hackernews: Add a "Suspense" wrapper. (#2253)
This warning appears in the browser's console log.

```
hackernews.js:933 At src/routes/stories.rs:39:17, you are reading a resource in `hydrate` mode outside a <Suspense/> or <Transition/>. This can cause hydration mismatch errors and loses out on a significant performance optimization. To fix this issue, you can either:
1. Wrap the place where you read the resource in a <Suspense/> or <Transition/> component, or
2. Switch to using create_local_resource(), which will wait to load the resource until the app is hydrated on the client side. (This will have worse performance in most cases.)
```
2024-02-03 14:24:46 -08:00
..
public Add Favicons to all the examples and standardize on the public folder for public assets 2023-01-09 15:27:52 -08:00
src examples/hackernews: Add a "Suspense" wrapper. (#2253) 2024-02-03 14:24:46 -08:00
Cargo.toml remove cfg-if from all examples 2024-01-19 14:16:58 -05:00
index.html Fix CSR with Trunk on hackernews example, remove CSR option from isomorphic example (#369) 2023-01-25 20:15:12 -05:00
LICENSE Updated hacker news example to new SFA format and added a README 2022-11-14 09:03:44 -08:00
Makefile.toml build(examples): make it easier to run examples (#1697) 2023-09-12 10:46:16 -04:00
README.md docs: make it easy to see how to run each example in its README (#2085) 2023-11-28 11:47:56 -05:00
rust-toolchain.toml chore: add rust-toolchain.toml to examples (closes #2151) (#2161) 2024-01-07 15:29:54 -05:00
style.css feat/change: adopt reactive ownership model and drop cx/Scope (#918) 2023-08-21 19:31:37 -04:00

Leptos Hacker News Example

This example creates a basic clone of the Hacker News site. It showcases Leptos' ability to create both a client-side rendered app, and a server side rendered app with hydration, in a single repository

Getting Started

See the Examples README for setup and run instructions.

Quick Start

Run trunk serve --open or cargo leptos watch to run this example.