First commit of i18n base blog using Eleventy v2. This uses English-implied URLs.

This commit is contained in:
Zach Leatherman
2022-07-15 12:11:54 -05:00
parent 70530889e4
commit 2491464043
26 changed files with 88 additions and 43 deletions

11
es/es.11tydata.js Normal file
View File

@@ -0,0 +1,11 @@
module.exports = {
"lang": "es",
"permalink": function(data) {
// Slug override is set in the post for localized URL slugs
// e.g. /es/blog/fourthpost.md will optionally write to
// /es/blog/cuarta-publicacion/ instead of /es/blog/fourth-post/
if(data.slugOverride) {
return `/${data.lang}/blog/${this.slugify(data.slugOverride)}/`;
}
}
}