Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
53 lines (40 sloc) 1.53 KB
<!DocType HTML>
<html lang="en-US"><head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>GitHub Web Widget Demo</title>
<!--[if lte IE 9]>
<script src="https://cdn.bootcss.com/html5-history-api/4.2.8/history.min.js"></script>
<![endif]-->
<script src="https://cdn.bootcss.com/MutationObserver.js/0.3.2/mutationobserver.min.js"></script>
<script src="https://cdn.bootcss.com/require.js/2.3.5/require.min.js"></script>
<script>
require.config({
paths: {
jquery: 'https://cdn.bootcss.com/jquery/3.2.1/jquery.min'
}
});
require(['jquery', 'EasyWebApp'], function ($) {
$.ajaxPrefilter('json', function (option, _, XHR) {
if ((new URL( option.url )).hostname === 'api.github.com')
XHR.setRequestHeader(
'Authorization',
'token 39ff883676bf43c5723e92701487a020ad1abfb2'
);
});
$( document ).ready(function () {
$('#EWA_box').iWebApp();
});
});
</script>
</head><body>
<h1>Example Widgets</h1>
<div style="max-width: 600px">
<div data-href="../source/Repository.html?repo=TechQuery/GitHub-Web-Widget">
</div>
<br>
<div data-href="../source/Profile.html?user=torvalds"></div>
</div>
<div id="EWA_box"></div>
</body></html>