pjsier / 11ty-starter-kit

Minimal starter project for 11ty static sites

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

11ty-starter-kit

Build status

Minimal starter project for 11ty designed for basic static sites with some interactive content.

This is based on some boilerplate setup I was copying between projects like ilfair.tax and this field guide to Chicago government.

Features

  • TailwindCSS for styles
  • Rollup for bundling JS for modern browsers using <script type="module">
  • Webpack for creating a bundle only served to legacy browsers like IE 11 through <script nomodule>
  • Minifies assets and includes them in inline tags
  • Basic templates in nunjucks, but also supports 11ty.js templates with an html tagged template literal for better editor support
  • Some reasonable defaults for Markdown, including opening external links in new tabs
  • Sets standard metadata tags and sitemap.xml
  • GitHub Actions deploy workflow

Get started

You can set up a project with this starter kit by clicking the "Use this template" button on this repo. Once you've created your project, you can get started with these steps.

  1. Clone your new repository (replace the URL with your repo)

    git clone https://github.com/<USERNAME>/<PROJECT>.git
    
  2. Move to the new project directory and install dependencies

    cd <PROJECT>
    npm install
    
  3. Start a local server to see if everything is working. You should be able to access your site at http://localhost:8080/

    npm start
    
  4. Change the project metadata in ./site/_data/site.js

About

Minimal starter project for 11ty static sites

License:MIT License


Languages

Language:JavaScript 44.5%Language:Nunjucks 33.4%Language:CSS 21.5%Language:HTML 0.7%