Skip to content
Small development server for Stakit
JavaScript CSS
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
example
lib
.gitignore
.npmignore
.npmrc
bin.js
index.js
package.json
readme.md
test.js

readme.md

monote

Small development server for Stakit

Work on static websites using Stakit without constantly regenerating them. Monote keeps the outputted files in memory, serves and automatically rebuilds them, so you can work and preview the site faster.

Stability NPM version

Installation

npm i monote

Usage

Export your kit without calling output() and let monote handle the rest. Just change your application or your Stakit build chain and monote will automatically rebuild the site using the new version.

// build.js
var stakit = require('stakit')

var kit = stakit()
  .routes(() => ['/'])
  .render((route, state) => `${route}`)

module.exports = kit

To start the development server run:

$ monote build.js

To build the site, simply pass an output path as an argument:

$ monote -o ./public build.js

This is useful if you don't want to check whether the build file was required or called directly.

CLI

usage
  monote [opts] <entry>
options
  --output, -o            build the site to the specified path
  --help, -h              show this help text
  --port, -p              server port
  --version, -v           print version
examples
  start server
  monote build.js

  start server on port 3000
  monote build.js -p 3000

  build site without dev server
  monote -o ./public build.js
You can’t perform that action at this time.