- new global variable debugMode - demo templates are now based on hippie defaults joined with template inheritance - add log macros - new function logAdd() - log uses global state
42 lines
1 KiB
JavaScript
42 lines
1 KiB
JavaScript
module.exports = function (eleventyConfig) {
|
|
eleventyConfig.setNunjucksEnvironmentOptions({
|
|
// throwOnUndefined: true,
|
|
trimBlocks: true
|
|
});
|
|
|
|
eleventyConfig.addGlobalData("permalink", () => {
|
|
return (data) => `${data.page.filePathStem}.${data.page.outputFileExtension}`;
|
|
});
|
|
|
|
eleventyConfig.addGlobalData("hippie", {
|
|
pageBase: './',
|
|
brand: 'hippie',
|
|
titlePrefix: '',
|
|
titlePostfix: ' - HIPPIE',
|
|
debugMode: true
|
|
});
|
|
|
|
eleventyConfig.addPassthroughCopy({"source/art/images": "art"});
|
|
|
|
eleventyConfig.addPassthroughCopy({"source/art/favicons/**/*.+(ico|png|svg)": "."});
|
|
|
|
eleventyConfig.addPassthroughCopy({"source/code/**/*.js": "js"});
|
|
|
|
eleventyConfig.addPassthroughCopy({"source/data/**/*.json": "json"});
|
|
|
|
eleventyConfig.addPassthroughCopy("vendor");
|
|
|
|
eleventyConfig.addWatchTarget("./source/style/");
|
|
|
|
return {
|
|
dir: {
|
|
input: "source/screens",
|
|
output: "build",
|
|
includes: "../templates",
|
|
data: "../data"
|
|
},
|
|
markdownTemplateEngine: "njk",
|
|
htmlTemplateEngine: "njk",
|
|
templateFormats: ["html", "njk", "md"]
|
|
}
|
|
};
|