Replace inline JS with meta tag template method

This commit is contained in:
Florine W. Dekker 2021-06-09 19:41:15 +02:00
parent 9370724b35
commit e82df88064
Signed by: FWDekker
GPG Key ID: 78B3EAF58145AF25
2 changed files with 8 additions and 14 deletions

View File

@ -1,6 +1,6 @@
MIT License
Copyright (c) 2021 Felix W. Dekker
Copyright (c) 2021 F.W. Dekker
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

20
dist/index.php vendored
View File

@ -44,6 +44,13 @@ if ($target != null && !$needs_confirmation) {
<meta name="description" content="FWDekker's tools" />
<meta name="theme-color" content="#0033cc" />
<meta name="fwd:nav:target" content="#nav" />
<meta name="fwd:header:target" content="#header" />
<meta name="fwd:header:title" content="fwdkr.co" />
<meta name="fwd:footer:target" content="#footer" />
<meta name="fwd:footer:vcs-url" content="https://git.fwdekker.com/FWDekker/fwdkr.co/" />
<meta name="fwd:footer:version" content="v1.4.1" />
<title>fwdkr.co</title>
<link rel="stylesheet" href="https://static.fwdekker.com/fonts/roboto/roboto.css" />
@ -97,17 +104,4 @@ if ($target != null && !$needs_confirmation) {
</main>
<script src="https://static.fwdekker.com/lib/template/2.x.x/template.js"></script>
<script>
// noinspection JSUnresolvedVariable
const {$, doAfterLoad, footer, header, nav} = window.fwdekker;
doAfterLoad(() => {
$("#nav").appendChild(nav());
$("#header").appendChild(header({title: "fwdkr.co"}));
$("#footer").appendChild(footer({
vcsURL: "https://git.fwdekker.com/FWDekker/fwdkr.co/",
version: "v1.4.0"
}));
});
</script>
</body>