Output to root dir #3367
-
I have a pretty large project with 5k+ files and <400MB of assets being passthrough copied over from src/assets to public/assets, and Git has been pretty slowpoke lately because of this. I was wondering if it's possible to render my public files into the root dir instead of a dedicated dir, so I would only have 1 assets folder that "public" can read from. Tried fiddling with eleventy.js but no cigar. Thanks for any input! Using Eleventy 2.0.1. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
You can configure passthroughcopy to put the files in a location of your choosing. See https://www.11ty.dev/docs/copy/#change-the-output-directory |
Beta Was this translation helpful? Give feedback.
-
See also this option which doesn’t copy files at all during development: https://www.11ty.dev/docs/copy/#emulate-passthrough-copy-during-serve |
Beta Was this translation helpful? Give feedback.
-
We solved our problem by gitignoring the public folder and setting up Netlify to run Eleventy server-side. I used to run 11ty locally and when everything was running, I would just push all files to Git. Now there's half as many files being run through Git which saves up lots of time and solved the lagging issue. :) |
Beta Was this translation helpful? Give feedback.
We solved our problem by gitignoring the public folder and setting up Netlify to run Eleventy server-side. I used to run 11ty locally and when everything was running, I would just push all files to Git. Now there's half as many files being run through Git which saves up lots of time and solved the lagging issue. :)