You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Im using the skeleventy starter project and have noticed that the Eleventy config file is called eleventy.config.js as oppose .eleventy.js as per the docs. When I run 'npm run dev' my site compiles and runs fine. However, If I rename my eleventy.config.js to .eleventy.js or use the eleventy command to build, I get the following error:
npx eleventy
Problem writing Eleventy templates: (more in DEBUG output)
> TemplateLayoutPathResolver directory does not exist for default: _includes
`Error` was thrown:
Error: TemplateLayoutPathResolver directory does not exist for default: _includes
at TemplateLayoutPathResolver.findFileName (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/TemplateLayoutPathResolver.js:96:13)
at TemplateLayoutPathResolver.init (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/TemplateLayoutPathResolver.js:61:28)
at new TemplateLayoutPathResolver (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/TemplateLayoutPathResolver.js:15:10)
at new TemplateLayout (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/TemplateLayout.js:15:24)
at Function.getTemplate (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/TemplateLayout.js:38:16)
at Template.getData (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/Template.js:219:37)
at async Template.getTemplateMapEntries (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/Template.js:681:16)
at async TemplateMap.add (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/TemplateMap.js:32:21)
at async Promise.all (index 5)
at async TemplateWriter._createTemplateMap (/Users/cbourne/development/11ty-hype/node_modules/@11ty/eleventy/src/TemplateWriter.js:132:5)
Wrote 0 files in 0.17 seconds (v0.10.0)
OK, so doing this eleventy --config=./eleventy.config.js seems to resolve the issue. However, it seems renaming the config file to .eleventy.js means it still doesn't get found by default.
I believe this error happens when you use the non-default includes folder (e.g. includes in your case) and you aren’t pointing to the --config file. So we look for the default _includes which doesn’t exist?
This is about Eleventy not knowing where your config file is, right?
This is an automated message to let you know that a helpful response was posted to your issue and for the health of the repository issue tracker the issue will be closed. This is to help alleviate issues hanging open waiting for a response from the original poster.
If the response works to solve your problem—great! But if you’re still having problems, do not let the issue’s closing deter you if you have additional questions! Post another comment and I will reopen the issue. Thanks!
Hi,
Im using the skeleventy starter project and have noticed that the Eleventy config file is called
eleventy.config.js
as oppose.eleventy.js
as per the docs. When I run 'npm run dev' my site compiles and runs fine. However, If I rename myeleventy.config.js
to.eleventy.js
or use theeleventy
command to build, I get the following error:My
eleventy.config.js
looks like this:And my directory structure looks like this:
Any guidance would be much appreciated.
The text was updated successfully, but these errors were encountered: