- Custom site variables are located in
_data/site.json
. These are used in the templates, such as_includes/shared/header.njk
. - Specifically, these are used to dynamically generate page titles and meta descriptions.
- Custom templates are located in
_includes/layouts
. - In order to use
layout: default
instead oflayouts/default.njk
, an alias was added to.eleventy.js
.
npm run start
- This runs
eleventy --serve
andparcel watch ./_assets/js/main.js --out-dir ./_site/assets
. --out-dir
ensures the assets generated byparcel
are loaded in the_site
directory generated byeleventy
.
- This runs
npm run build
- This runs
eleventy
andparcel build ./_assets/js/main.js --out-dir ./_site/assets
. parcel build
minifies everything.--out-dir
ensures the assets generated byparcel
are loaded in the_site
directory generated byeleventy
.
- This runs
- Bootstrap is loaded via npm, and then imported in at
_assets/css/vendor/_bootstrap.scss
- Bootstap overrides are located at
_assets/css/base/_bootstrap-overrides.scss
. - All
.scss
files are imported into_assets/css/main.scss
. _assets/css/main.scss
is then imported into_assets/js/main.js
._assets/js/main.js
is then bundled via Parcel. Parcel magically creates a_site/assets/main.css
and_site/assets/main.js
from this file.