-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eleventy.js
42 lines (35 loc) · 1.01 KB
/
.eleventy.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
/**
* @file Eleventy’s configuration file
* @author Reuben L. Lillie <rlilie@pghnaz.org>
*/
// Require local modules
var fileToString = require('./src/includes/filters/file-to-string')
var minifyCSS = require('./src/includes/filters/minify-css')
/**
* Expose the configuration to 11ty as a function
* @module .eleventy
* @param 11ty’s config argument
* @see {@link https://www.11ty.io/docs/config/ 11ty docs}
*/
module.exports = function (eleventyConfig) {
// Pass 11ty config argument to local modules
fileToString(eleventyConfig)
minifyCSS(eleventyConfig)
/**
* Copy static assets directly from includes to output
* @see {@link https://www.11ty.io/docs/copy/ 11ty docs}
*/
eleventyConfig.addPassthroughCopy('src/includes/assets')
/**
* Overwrite 11ty’s default configuration options
* @see {@link https://www.11ty.io/docs/config/ 11ty docs}
*/
return {
dir: {
data: 'data', // relative to input
includes: 'includes', // relative to input
input: 'src',
output: 'dist'
}
}
}