-
Notifications
You must be signed in to change notification settings - Fork 48
/
.eleventy.js
31 lines (29 loc) · 918 Bytes
/
.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
const syntaxHighlight = require('@11ty/eleventy-plugin-syntaxhighlight')
require('prismjs/plugins/custom-class/prism-custom-class')
const markdownIt = require('markdown-it')
const markdownItAnchor = require('markdown-it-anchor')
module.exports = function (eleventyConfig) {
const markdownLibrary = markdownIt().use(markdownItAnchor, {
permalink: markdownItAnchor.permalink.headerLink()
})
eleventyConfig.setLibrary('md', markdownLibrary)
eleventyConfig.addPlugin(syntaxHighlight, {
init: function ({ Prism }) {
Prism.plugins.customClass.prefix('prism--')
}
})
eleventyConfig.setUseGitIgnore(false)
eleventyConfig.addPassthroughCopy('CNAME')
eleventyConfig.addPassthroughCopy({
'node_modules/@fortawesome/fontawesome-free/webfonts': 'fonts/fontawesome'
})
eleventyConfig.setTemplateFormats([
'html',
'md',
'njk',
'css',
'jpg',
'map',
'svg'
])
}