2015-01-08 15:45:30 +01:00
|
|
|
<!DOCTYPE html>
|
|
|
|
{{comment .License}}
|
2015-01-09 16:38:17 +01:00
|
|
|
<script>
|
|
|
|
'use strict';
|
|
|
|
window.addEventListener('load', function() {
|
|
|
|
function isProduction() {
|
|
|
|
var l = window.top.location;
|
|
|
|
if (l.hash === '#_production') {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
if (l.hostname === 'localhost' || l.hostname === '127.0.0.1') {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
var s = document.createElement('script');
|
|
|
|
var src = '{{.Example.Name}}.js';
|
|
|
|
if (isProduction()) {
|
|
|
|
src = 'http://hajimehoshi.github.io/ebiten.pagestorage/{{.CurrentBranch}}/' + src;
|
|
|
|
}
|
|
|
|
s.src = src;
|
|
|
|
document.body.appendChild(s);
|
|
|
|
});
|
|
|
|
</script>
|