htmx · console.warn
htmx could not store this page's history sna...
Printed by htmx, prefixed [lattice], since 1.83.0.
Warnings reference › htmx:history-snapshot-too-large
- Identifier
htmx:history-snapshot-too-large- Raised by
- htmx
- Since
- 1.83.0
What happened
Even after the htmx module shrank the snapshot to the original table markup, htmx hit its sessionStorage quota (~5 MB) and dropped the history entry, so browser Back re-fetches the page rather than restoring the grid's sort, filter and scroll position.
The fix
Scope the hx-history-elt subtree to just the table (not the whole page), or cap htmx's historyCacheSize so fewer snapshots are kept.
The smallest fix
<div hx-history-elt>
<table data-lattice-grid>…</table>
</div>
Reference
Covered in full at the API reference.