Skip to content

Instantly share code, notes, and snippets.

@bobmonsour
Created August 22, 2024 20:58
Show Gist options
  • Save bobmonsour/2b209c6c7c63da0aa8a0e1f4970bc6df to your computer and use it in GitHub Desktop.
Save bobmonsour/2b209c6c7c63da0aa8a0e1f4970bc6df to your computer and use it in GitHub Desktop.
Simplify eleventy config via Trevor Morris
for (const [name, filter] of Object.entries(filters)) {
if (['getDescription', 'getRSSlink'].includes(name)) {
eleventyConfig.addAsyncFilter(name, filter)
} else {
eleventyConfig.addFilter(name, filter)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment