mirror of
https://github.com/bigskysoftware/htmx.git
synced 2025-09-27 04:50:43 +00:00

* Move History storage to sessionStorage and history path to window * Fix type warnings * Revert currentPathForHistory to move it to its own PR * fix test
20 lines
735 B
HTML
20 lines
735 B
HTML
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<script type="application/javascript" src="../../../src/htmx.js"></script>
|
|
<title>History - Regression 2 Page 1</title>
|
|
<script>
|
|
htmx.on("htmx:beforeHistorySave", function(evt){
|
|
console.log("Saving history : ", evt.detail);
|
|
console.log("History Cache Before:", JSON.parse(sessionStorage.getItem("htmx-history-cache")))
|
|
setTimeout(function () {
|
|
console.log("History Cache After:", JSON.parse(sessionStorage.getItem("htmx-history-cache")))
|
|
}, 10);
|
|
})
|
|
</script>
|
|
</head>
|
|
<body style="padding:20px;font-family: sans-serif" hx-boost="true">
|
|
<a href="page2.html">To Page 2</a>
|
|
</body>
|
|
</html>
|