node package manager
Painless code sharing. npm Orgs help your team discover, share, and reuse code. Create a free org »

enoki

Enoki

Enoki is a set of tools for self-publishing websites.

If you’re looking for a place to start, take a look at the Starter Kit.

Features

  • no database: use folders and files to structure your site
  • static: no server-side code needed here!
  • hydrated: hydrate your static output with isomorphic js
  • flexible: great defaults, super customizable
  • archivable: totally portable and future-proof
  • managable: appropriate for small to mid-sized projects

Pre-alpha! Not ready for production! Bugs everywhere! No testing! Limited documentation! Boo!!

Usage

Enoki transforms your content into a static site. It’s suggested you use the Starter Kit during pre-alpha. You can use Enoki either as a command line interface or a javascript module.

View the cli --help
--verbose, -v  Show version number                  [boolean] [default: false]
--output, -o   Build output dir                            [default: "build/"]
--site, -s     Site dir                                     [default: "site/"]
--content, -c  Content dir                               [default: "content/"]
--assets, -a   Assets dir                                 [default: "assets/"]
--live, -l     Live reloading                                  [default: true]
--panel, -p    Panel dir                                   [default: "panel/"]
--port, -P     Listen on port                                  [default: 8080]
--portpanel    Panel listen on port                            [default: 8081]
--portapi      Api listen on port                              [default: 8082]
--config, -C   Config file                             [default: "config.yml"]
-h, --help     Show help                                             [boolean]

Build

enoki build

Provided a valid directory structure, transform your content into a static site.

Development

enoki dev

Spin up a Budo development server and watch for changes. If you’d like to customize this configuration during pre-alpha, check out the Browserify Transform.

Panel

enoki panel

Run the Enoki panel, which provides an ultralight web interface for managing your site’s content. Note that during pre-alpha you must have the panel placed locally next to your site. For an example, take a look at the Starter Kit.

Browserify Transform

browserify index.js -o bundle.js -t require-globify -t enoki/transform

The Browserify transform can be used in your custom build. It inlines your directory into JSON. For the pre-alpha, the transform also requires require-globify.

Starter Kit

The intent is to make a modular set of tools, but during pre-alpha some of these parts are tightly bound. Because of this, it isn’t expected that any one will use the CLI javascript module on it’s own just yet.

Instead, it’s suggested you download the Starter Kit to get an example structure of a fully working site. Future documentation will cover each individual module in detail, but for now what follows is a walk-through of the Starter Kit.

Download the Starter Kit