wordpos/samples/self-hosted/index.html

40 lines
927 B
HTML

<!doctype html>
<html>
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/github.min.css" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/languages/javascript.min.js"></script>
<script src="./main.js"></script>
<style>
pre {
padding: 2em;
display: block;
}
</style>
</head>
<body>
<h1>Self-hosted WordPOS sample</h1>
Open console to see results.
<pre><code> </code></pre>
<script>
var el = document.querySelector('code');
if (fetch) {
fetch('./main.txt')
.then(res => res.text())
.then(txt => {
el.innerText = txt;
hljs.initHighlightingOnLoad();
});
} else {
el.innerHTML = 'Open <a href=main.txt>main.js</a>.';
}
</script>
</body>
</html>