Twig based Static Site generator powered by gulp.
There are a lot of static site generator out there but we always found ourselves tweaking and adjusting them. The idea is to use it as a boiler plate for basic static web sites. Tailored to our needs and workflows, its intended to use as it is with no config required. Heavily inspired on Jekyll.
-
- Basic installation, nothing fancy. https://nodejs.org
- From: https://github.com/oierbravo/pleasure/archive/0.3.zip
- Last
release
recommended.
- Launch
npm
installernpm install
- Launch development environment
npm start
- Clean previous builds.
npm run clean
- Compile everything for production.
npm run build
- Build command:
npm run build
- Publish directory:
build
Some simples and some advanced.
|-- build/ (generated production build)
|-- build-dev/ (generated development build)
|-- src/assets/fonts/ (font sources)
|-- src/assets/images/ (image sources)
|-- src/assets/js/ (js sources)
|-- src/assets/scss/ (SMACSS based sass setup)
|-- src/assets/svg/ (svg sources)
|-- src/assets/videos/ (video sources)
|-- gulpfile.js (configured gulp file)
|-- node_modules/ (modules generated by npm)
|-- package.json (configured to load dependencies by npm)
|-- config.vendors.js (javascript vendor configuration file example)
|-- README.md (Documentation)
BEM & Atomic design structure.
src/assets/sass/
|-- 01_tools/
|-- 02_settings/
|-- 03_generic/
|-- 04_elements/
|-- 05_objects/
|-- 06_components/
|-- 07_pages/
|-- 08_utilities/
|-- style.scss
src/pages/
|-- _components/ (reusable twig components)
|-- _data/ (site data and specific page data)
|-- _includes/ (common place for include files)
|-- _layouts/ (html and page layout)
|-- page1/index.twig (example page)
|-- page2/index.twig (example page with partials)
|-- dev-guide.twig (pages, components and svg icons index, for development purposes)
|-- index.twig
Normal NetlifyCMS config file. Modify as needed. name
act as machinename. Important for folder naming and final url.
src/pages/content-name
|-- list.twig (content list page)
|-- item.twig (content item page)
content/content-name
|-- slug.json (a file per item)
and how to use them.
- Critical split - missing string inject into style
- Responsive images
- Documentation
- Default non intrusive html and sass
- Favicon gen