Skip to content

Commit

Permalink
Add demo directory
Browse files Browse the repository at this point in the history
  • Loading branch information
addyosmani committed Nov 23, 2018
1 parent d417c9c commit 67784f7
Show file tree
Hide file tree
Showing 6 changed files with 96 additions and 0 deletions.
15 changes: 15 additions & 0 deletions demo/1.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Prefetch experiments</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="main.js"></script>
</head>
<body>
<h1>Page 1</h1>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta est sint assumenda corrupti minima aut, magnam totam beatae ullam ea iste voluptatum iusto expedita animi rem vitae rerum atque nemo!</p>
</body>
</html>
15 changes: 15 additions & 0 deletions demo/2.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Prefetch experiments</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="main.js"></script>
</head>
<body>
<h1>Page 2</h1>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta est sint assumenda corrupti minima aut, magnam totam beatae ullam ea iste voluptatum iusto expedita animi rem vitae rerum atque nemo!</p>
</body>
</html>
15 changes: 15 additions & 0 deletions demo/3.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Prefetch experiments</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="main.js"></script>
</head>
<body>
<h1>Page 3</h1>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta est sint assumenda corrupti minima aut, magnam totam beatae ullam ea iste voluptatum iusto expedita animi rem vitae rerum atque nemo!</p>
</body>
</html>
15 changes: 15 additions & 0 deletions demo/4.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Prefetch experiments</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="main.js"></script>
</head>
<body>
<h1>Page 4</h1>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta est sint assumenda corrupti minima aut, magnam totam beatae ullam ea iste voluptatum iusto expedita animi rem vitae rerum atque nemo!</p>
</body>
</html>
33 changes: 33 additions & 0 deletions demo/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Prefetch experiments</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="https://polyfill.io/v2/polyfill.min.js?features=IntersectionObserver"></script>
<!-- <script src="main.js"></script> -->
</head>
<body>
<a href="1.html">Link 1</a>
<a href="2.html">Link 2</a>
<a href="3.html">Link 3</a>
<section id="stuff">
<a href="main.css">CSS</a>
</section>
<a href="4.html" style="position:absolute;margin-top:900px;">Link 4</a>
<!-- <script src="index.js"></script> -->
<script type="module">
import quicklink from "../src/index.mjs";
quicklink();
// quicklink({
// urls: ['2.html','4.html']
// });
// let elem = document.getElementById('stuff');
// quicklink({
// el: elem
// });
</script>
</body>
</html>
3 changes: 3 additions & 0 deletions demo/main.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
body {
font-family: Roboto, Arial, sans-serif;
}

0 comments on commit 67784f7

Please sign in to comment.