feat: set automatic year for copyright on build time
This commit is contained in:
@@ -49,6 +49,10 @@ module.exports = function(eleventyConfig) {
|
||||
ul: true,
|
||||
});
|
||||
|
||||
eleventyConfig.addShortcode('getYear', () => {
|
||||
return new Date().getFullYear();
|
||||
});
|
||||
|
||||
eleventyConfig.addFilter("env", (key, def="NOT DEFINED") => process.env[key] || def);
|
||||
|
||||
eleventyConfig.addFilter("readableDate", (dateObj, format = "dd LLLL yyyy") => {
|
||||
|
@@ -47,7 +47,7 @@
|
||||
<div class="footer-contact">
|
||||
<div>
|
||||
<p class="footer-contact-title">IT's on us</p>
|
||||
<p>Copyright © 2022</p>
|
||||
<p>Copyright © {% getYear %}</p>
|
||||
</div>
|
||||
<ul class="footer-links">
|
||||
<li>
|
||||
|
Reference in New Issue
Block a user