Awesome
Eleventy Web Starter
An opinionated starter template for building static websites using Eleventy. This starter kit is designed to help you quickly set up a modern, fast, and efficient static site with best practices for templating, styling, and performance optimisation.
āØ Features
- Eleventy (11ty) for static site generation
- Nunjucks templating language and Markdown support
- SCSS for modular and maintainable styling
- ESBuild for fast and efficient bundling of JavaScript
- Image Optimisation using Eleventy plugins
- Live Reload for rapid development
- SEO Optimizations and social sharing metadata
- Pre-configured for easy deployment to Netlify, Vercel, or GitHub Pages
š ļø Tech Stack
- Static Site Generator: Eleventy (11ty)
- Templating Languages: Nunjucks, Liquid, Markdown
- Styling: SCSS, PostCSS
- JavaScript: ES6 Modules
- Build Tool: ESBuild
- Deployment: Netlify, Vercel, GitHub Pages
š Getting Started
Prerequisites
Make sure you have the following installed on your machine:
Installation
-
Clone the Repository:
git clone https://github.com/chrissy-dev/eleventy-web-starter.git cd eleventy-web-starter
-
Install Dependencies:
npm install
Or, if using Yarn:
yarn install
Running the Project
Start the local development server:
npm run dev
This command will:
- Build the project using Eleventy
- Watch for changes in source files
- Serve the project at
http://localhost:8080
- Enable live reload for a smooth development experience
Building for Production
To generate a production-ready build, run:
npm run build
The output will be in the dist
folder, optimised and ready for deployment.
š Project Structure
Here's an overview of the core structure of this project:
eleventy-web-starter/
āāā src/ # Source files for the project
ā āāā _data/ # Data files in JSON or JS format
ā āāā _includes/ # Reusable components
ā āāā _layouts/ # Reusable layouts
ā āāā _assets/ # Assets - JS, CSS (Tailwind)
āāā .eleventy.js # Eleventy configuration file
āāā package.json # Node dependencies and scripts
āāā tailwind.config.js # Tailwind Config
āāā postcss.config.js # PostCSS Config
āāā README.md # Project documentation
š Available Scripts
npm start
: Start the development server with live reload.npm run build
: Create a production build of the site.npm run clean
: Remove thedist
folder to reset the build.
š Deployment
This starter is optimised for deployment on popular static site hosts. Follow the instructions below for different providers:
Netlify
-
Click the button below to deploy to Netlify:
-
Configure the build settings:
- Build Command:
npm run build
- Publish Directory:
dist
- Build Command:
Vercel
-
Install the Vercel CLI if not already installed:
npm install -g vercel
-
Deploy using the Vercel CLI:
vercel
-
Follow the prompts to complete the deployment.
š¤ Contributing
Contributions, issues, and feature requests are welcome! Feel free to check the issues page.
To contribute:
- Fork the repository
- Create a new branch (
git checkout -b feature-branch
) - Commit your changes (
git commit -m 'Add a new feature'
) - Push to the branch (
git push origin feature-branch
) - Open a Pull Request
š License
This project is MIT licensed.
š§ Contact
If you have any questions or need further assistance, feel free to reach out:
- GitHub: chrissy-dev