Built specifically to manage jaschaephraim.com, and explained in detail in this article on medium.com.
Creates new project template.
Starts development environment. Compiles everything (without writing to files), starts watcher and server.
Exports project to a static site with the structure:
[project-root]/
├──app.min.css
├──app.min.js
├──┬fonts/
│ ├──[font-one/]
│ └──[font-two/]
├──┬img/
│ ├──[image-one.jpg]
│ └──[image-two.png]
└──index.html
Exports to index.html
.
Exports to app.min.css
.
Exports to app.min.js
. Can include CommonJS style require()
, and you can require anything in bower_components/
by its package name.
Contents copied recursively to /
upon export. For images, fonts, etc.
Each Markdown file in content/
represents an individual piece of content. Metadata can be included in YAML front matter, and will be available to Jade templates. The compiled markdown (which should not be html-escaped) itself is stored in the property body
.
Similar to content/
, each Markdown file represents a tag. Each file should define at least a content
list in its YAML, listing the file names (without .md
extension) that are included in the tag.
content/chihuaha.md
:
---
title: Chihuahua
---
Chihuahuas are the best.
tags/dogs.md
:
---
title: Dogs
content:
- chihuaha
---
I like dogs!
jade/index.jade
:
doctype html
html
head
title= tags.dogs.title
body
h1= tags.dogs.title
div!= tags.dogs.body
each dog in tags.dogs.content
h2= content[dog].title
div!= content[dog].body
Will render to index.html
as:
<!DOCTYPE html>
<html>
<head>
<title>Dogs</title>
</head>
<body>
<h1>Dogs</h1>
<div>
<p>I like dogs!</p>
</div>
<h2>Chihuahua</h2>
<div>
<p>Chihuahuas are the best.</p>
</div>
</body>
</html>