Help and mentoring

So I’m developing 11ty on my macbook for the first time, and I also set up a local repository for it for the first time. I set it up as per eleventy from scratch lessons 1 & 2, just like my portfolio site. However, it writes everything to a _site folder, not dist.

In the root, I have my src folder where I have the files I’ve set up but when I run eleventy it writes everything into the _site folder that it made, including both the src and dist. If I delete the _site folder it makes another.

Is this a git thing? Do I need to just go with it?

[Image Alt: The folder structure of my eleventy project as seen in VS Code. There’s a _site folder, src folder and dist folder inside the root.]

I’d get ride of that _site folder as it looks like it’s actually writing to dist. If in doubt: download the project files at the end of the lesson :slight_smile:

Ok solution took some time, but the pain was worth the knowledge acquisition, imo.

Short answer:
If you’re on Windows 10, pay attention to Lesson 1, install WSL and learn to use it. Its worth it!

Long answer:
My OS is Windows 10, had never previously had problems with Eleventy or npm plugins. And yet this project’s plugins were causing weird hard-to-fix problems.

As it was, I already had WSL enabled (Windows Subsystem for Linux) with Debian as the OS, but discovered that I wasn’t properly using it :man_facepalming:

Went back to Lesson 1 & went through both the video and post to make sure I better understood it.
Video: https://www.youtube.com/watch?v=_fntjriRe48
Post: https://fatsackfails.com/posts/eleventy-windows/
Btw, there’s no need to use Hyper…the Linux-flavor terminal is sufficient. In my case, I got a Debian terminal (and right-clicked to change Defaults opacity to make it look slightly funkier :slight_smile:)

In essence, the above loads a Linux subsystem onto your Windows, and provides you with a corresponding terminal that accesses that system, showing its different folder structure (eg. /home, /root, /bin etc).

You can see those files using Windows Explorer (eg. via \\wsl$\Debian or \\wsl$\Ubuntu), or open Explorer from the terminal by using the command Explorer.exe . (note that the final dot opens to the pwd folder)

If you want to use Explorer rather than a terminal, you can download or move your files into your home directory (I created /home/projects/learn-eleventy-from-scratch and loaded Lesson 22’s files into that).

Then CD to that folder in your terminal, and use command code . to launch VS Code with the folder already loaded.

Almost done, but I first needed to load my node modules, so I referred back to the fatsackfails Post linked above and realized I had to:

  1. install curl
  2. install nvm

Cool, I was now able to install node + npm.

Lastly, I had to run npm update to fix an issue with gulp-imagemin, which was giving me weird EPIPE error messages. The update fixed that.

In hindsight, I guess all that could be done in an hour or two (rather than the days of faffing around it took me because I didn’t know what I was doing). And while its just a file structure at this stage, if GUI applications are desired its easy to load the different Linux desktops, such as XCFE.

Anyway, end result is you get a Linux subsystem to work on within Windows, without having to dual boot. In my view, that’s a huge amount of quick & extra flexibility, so definitely worth the effort! :slightly_smiling_face:

Looks like I’d overwritten a line in the .eleventy.js file. Cleaned that up and it worked again :joy: I guess I just needed a few days away!

1 Like

Fresh eyes FTW! :rocket::rocket::rocket::rocket:

1 Like

Hi There,

I am stuck on chapter 7 and from what I can tell in comparing my code to the downloaded files, everything looks the same. What is not working is that I can’t get the text underneath the image to show up.

I’m new to this way of working, so when I look in the console I don’t see any errors.

What is the best way to troubleshoot these type of issues?

Thanks!!
Elli

Howdy :wave:

Sorry to hear this!

Sorry to ask the basics, but have you tried replacing all of your code with the downloaded files?

Hi! I’m a junior web dev and I would like to ask about what tools I should use for a project. My client asked me to make a blog for him so I planned to use 11ty. He would also like a book club and a way for his community to engage with his posts. He plans to use it to use the blog to write about his podcasts and let his community know about the next stream. Will it be alright if I use 11ty for the blog and make another app for the community engagement and book club? could you recommend me some tools or frameworks?