forked from hampusohlsson/browser-deeplink
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexample.html
44 lines (41 loc) · 963 Bytes
/
example.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<!doctype html>
<html>
<head>
<meta name="viewport" content="initial-scale=1, maximum-scale=1">
<script src="browser-deeplink.js" type="text/javascript"></script>
<script type="text/javascript">
deeplink.setup({
iOS: {
appId: "284882215",
appName: "facebook",
},
android: {
appId: "com.facebook.katana"
}
});
function clickHandler(uri) {
deeplink.open(uri);
return false;
}
</script>
<style>
*, *:before, *:after {
box-sizing: border-box;
}
a {
font-family: monospace;
display: block;
width: 100%;
margin: 10px 0;
padding: 25px;
background: #060;
color:#fff;
text-align: center;
font-size: 20px;
}
</style>
</head>
<body>
<a href="#" data-uri="fb://profile" onclick="clickHandler(this.dataset.uri)">open fb://profile</a>
</body>
</html>