{{ define "main"}} | |
<script> | |
var reg = /\/docs\/[a-zA-Z\-]+\/([\w|\.]+)\//; | |
var res = reg.exec(location.href); | |
var version = res && res[1]; | |
if (version === 'latest') { | |
var newUrl = location.href.replace('/latest/', '/next/'); | |
window.location.href = newUrl | |
} | |
</script> | |
<main id="main"> | |
<div class="mt-4 text-center"> | |
<h1 id="title">Not found</h1> | |
<p>Oops! This page doesn't exist. Try going back to our <a href="{{ "/" | relURL }}">home page</a>.</p> | |
</div> | |
</main> | |
{{ end }} |