Add webpack for css and js

This commit is contained in:
Tom Raithel
2017-01-25 11:44:16 +01:00
parent 9d6402d7fd
commit 74bfec3366
11 changed files with 58 additions and 5 deletions

22
tasks/template.js Normal file
View File

@@ -0,0 +1,22 @@
import pug from 'pug';
import { relativePath } from './file';
const templateFolder = 'templates';
export const vars = (vars) => ({
translate: (text) => {
const mappings = {
'languages-and-frameworks': 'Languages & Frameworks',
'methods-and-patterns': 'Methods & Patterns',
'platforms-and-aoe-services': 'Platforms and AOE Services',
'tools': 'Tools',
};
return mappings[text.trim()] || '-';
},
...vars,
})
export const item = pug.compileFile(relativePath(templateFolder, 'item.pug'));
export const quadrant = pug.compileFile(relativePath(templateFolder, 'quadrant.pug'));