GitXplorerGitXplorer
c

erikburns.com

public
0 stars
0 forks
0 issues

Commits

List of commits on branch main.
Unverified
6a1ebe4e9a4bbc209b3429b1b863c993fd1411e7

another small deploy test

committed 3 months ago
Unverified
2b7d1e4d703ba6711a0d29118de2722d14b3676a

fixing eleventy conf to passthrough cname

committed 3 months ago
Unverified
7a8abe29479ae71ea618a6e9b1ba9a22a2e714e7

Fixing CNAME resolution issue for gh-pages

committed 3 months ago
Unverified
dbad02d7a95a0a89982aa9bc4e91feb27c38150a

another small homepage test for deploy process

committed 3 months ago
Unverified
0ab3fe70e056793a48b94eebc9adb8383a5d7a09

small homepage copy change to test deploy

committed 3 months ago
Unverified
5c72ce6948a998724f53cad53d6ce65d68c62357

Add gh-pages deploy script and update package.json

committed 3 months ago

README

The README file for this repository.

Erik Burns' Eleventy Project

Overview

This project is built with the Eleventy static site generator and follows an advanced folder structure based on the principles of Separation of Concerns (SoC). The purpose of this structure is to improve readability, maintainability, and scalability as the project grows.

The structure was adapted from this blog post and this blog post, which explains how to optimize Eleventy projects as they expand in complexity.

Folder Structure

Here's the advanced folder structure implemented in this project:

├── 11ty/             # Eleventy build scripts
    ├── collections/  # Collections
    ├── filters/      # Filters
    ├── shortcodes/   # Shortcodes
    └── utils/        # Utility functions/helpers
├── src/              # Main input folder
    ├── _include/     # Partial templates
    ├── _layout/      # Page layouts
    ├── _data/        # Global data files
    ├── assets/       # Static assets
        ├── fonts/    # Fonts
        ├── img/      # Images
        ├── js/       # JavaScript files (raw and ES6+ to be bundled)
        └── styles/   # SCSS (compiled to CSS)
├── dist/             # Output folder
    └── assets/       # Assets (compiled CSS, JS, optimized images, etc.)

Rationale Behind This Structure

  • Separation of Concerns: The structure is designed to keep different parts of the project organized and isolated. Content, templates, static assets, and build logic are separated for better maintainability. All build-related logic is contained within the 11ty/ folder, while content and static assets are in src/.
  • Input and Output Folders: The /src folder is used for all inputs (content, templates, and static assets), while the /dist folder is used for the output (the built, production-ready site). This clear separation ensures that source files and generated files are easily distinguishable.
  • Partial Templates and Layouts: Partial templates are stored in src/_include/ for reusable components, while full-page layouts are kept in src/_layout/.
  • Static Assets: Raw static assets like fonts, images, JavaScript, and SCSS files are stored in src/assets/. These assets are either copied directly or processed (compiled SCSS, bundled JavaScript) into /dist/assets/ for the final site.

Future Improvements

  • Add additional shortcodes, filters, and collections as needed inside the 11ty/ folder to extend Eleventy's functionality.
  • Implement a more robust build process for CSS/SCSS and JavaScript in the src/assets/scss/ and src/assets/js/ directories, including automatic minification and bundling for production builds.
  • Explore adding additional utility functions in the 11ty/utils/ folder to streamline reusable logic across filters, collections, and shortcodes.