Edit
Loaders
Loaders help load content asynchronously when the HTML page is rendered. The module currently contains only one loader requiring HTMX enabled.
Lazy Loader
#1 from ludic.catalog.loaders import LazyLoader 2 3 LazyLoader(load_url="https://example.com/huge-image.png")
The default placeholder displayed before the content is loaded looks like this:
However, you can use your own placeholder:
1 from ludic.catalog.loaders import LazyLoader, Loading 2 3 LazyLoader( 4 load_url="https://example.com/huge-image.png", 5 placeholder=Loading(), # replace with your own placeholder 6 )