Skip to content

Commit c52dfef

Browse files
committed
Update README.md
1 parent f7cb399 commit c52dfef

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

Diff for: README.md

+12
Original file line numberDiff line numberDiff line change
@@ -1 +1,13 @@
11
mini SPA sample
2+
3+
header title's anchor is not ajax request.
4+
5+
if want to ajax, execute following code at console.
6+
7+
```
8+
document.querySelector('header h1 a').addEventListener('click', function(e){
9+
e.preventDefault();
10+
history.pushState(null, null, '/');
11+
pageLoad();
12+
});
13+
```

0 commit comments

Comments
 (0)