mirror of
https://github.com/Wolvan/poll.horse.git
synced 2024-11-25 06:07:58 +01:00
Serverside render footer
This way it's easy to add new links or a changed copyright to the footer on all pages.
This commit is contained in:
parent
3e06f08e42
commit
5b5dc9d922
2 changed files with 7 additions and 3 deletions
|
@ -51,9 +51,9 @@
|
||||||
</main>
|
</main>
|
||||||
<footer>
|
<footer>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="https://github.com/Wolvan/poll.horse" target="_blank">Github Repo</a></li>
|
{{ FOOTER_LINKS }}
|
||||||
</ul>
|
</ul>
|
||||||
<div class="copyright">© 2021 Wolvan</div>
|
<div class="copyright">{{ FOOTER_COPYRIGHT }}</div>
|
||||||
</footer>
|
</footer>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -55,7 +55,11 @@ class MinificationTransform extends RenderTransform {
|
||||||
|
|
||||||
const defaultReplacements = {
|
const defaultReplacements = {
|
||||||
"TITLE": "Poll Horse",
|
"TITLE": "Poll Horse",
|
||||||
"DEVELOPER_CONTACT_INFO": "developer@poll.horse"
|
"DEVELOPER_CONTACT_INFO": "developer@poll.horse",
|
||||||
|
"FOOTER_COPYRIGHT": `© ${ (new Date()).getFullYear() } Wolvan`,
|
||||||
|
"FOOTER_LINKS": `
|
||||||
|
<li><a href="https://github.com/Wolvan/poll.horse" target="_blank">Github Repo</a></li>
|
||||||
|
`
|
||||||
};
|
};
|
||||||
class Defaults2RenderTransform extends MinificationTransform {
|
class Defaults2RenderTransform extends MinificationTransform {
|
||||||
constructor(replacements = {}) {
|
constructor(replacements = {}) {
|
||||||
|
|
Loading…
Reference in a new issue