A simple structure for generating blogs, content-focused websites, and other MPAs as static sites using Eleventy and WebC, with a src/routes-based folder structure.
- JavaScript 79.5%
- SCSS 11.9%
- Dockerfile 8.6%
| nginx.default.d | ||
| src | ||
| tests | ||
| .cliff.toml | ||
| .containerignore | ||
| .eleventyignore | ||
| .env.example | ||
| .gitignore | ||
| .nvmrc | ||
| CHANGELOG.md | ||
| Containerfile | ||
| eleventy.config.js | ||
| package-lock.json | ||
| package.json | ||
| playwright.config.js | ||
| README.md | ||
Yet Another Eleventy Blog
A simple structure for generating blogs, content-focused websites, and other
MPAs as static sites using Eleventy and WebC, with a src/routes-based folder
structure.
🚀 Features
- Project structure and examples for a simple site.
- Containerfile for RHEL UBI-based nginx container deployment.
- WebC components and templating support with global imports.
- Bundled SASS/SCSS/JS compilation in build.
- Use photos as data to generate gallery pages, etc.
- Basic SEO controls for titles, meta descriptions, robots.
- Basic test suite to check for common accessibility errors.
Project structure
This repo does not reflect the normal Eleventy structure. Instead, it
is structured to prioritize webc components and to easily infer URL
structure from the repo's internal structure.
For example, src/routes/blog/{date}/{title}.webc
should represent a template that generates pages using external data
with URLs based on date and title.
Example project structure
.
├── eleventy.config.js # Configure directory settings
└── src
├── components # Import all *.webc files as components
│ └── component.webc
├── data # Global data files belong here
│ └── site.json
├── includes # Global css, partials, etc. belong here
│ └── scss
│ └── global.scss
├── layouts # Nesting "layout" files belong here
│ └── base.webc
└── routes # Paths should mirror final URL paths
├── assets # Good place for standalone resources
├── index.webc
└── routes.11tydata.json # Default frontmatter for all routes