summaryrefslogtreecommitdiffstatshomepage
path: root/test/manual/history_regression2/page2.html
blob: b72c59b209f84ef9ffc849041eebb6fec7d2eda6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<html lang="en">
<head>
    <meta charset="utf-8" />
    <script type="application/javascript" src="../../../src/htmx.js"></script>
    <title>History - Regression 2 Page 2</title>
    <script>
        htmx.on("htmx:beforeHistorySave", function(evt){
            console.log("Saving history : ", evt.detail);
            console.log("History Cache Before:", JSON.parse(localStorage.getItem("htmx-history-cache")))
            setTimeout(function () {
                console.log("History Cache After:", JSON.parse(localStorage.getItem("htmx-history-cache")))
            }, 10);
        })
    </script>
</head>
<body style="padding:20px;font-family: sans-serif" hx-boost="true">
<a href="index.html">Back To Page 1</a>
<p>History Element should read 'History - Regression 2 Page 1'</p>
</body>
</html>