Skip to content

mspg/core

Repository files navigation

mspg - magic static page generator

NPM version Linux Build Status Windows Build Status Coverage Status Greenkeeper badge

transforms a src directory into a github hosted gh-pages branch.

installation
npm i --save mspg/core
usage

mspg comes as a single executable file.

mspg [TASKS]...

available tasks:
clean   - deletes the public directory
build   - builds the src dir to public
serve   - serves the public dir
zip     - gzips the public dir using zopfli
connect - connects the git repository to it's gh-pages branch
publish - publishes the current HEAD to github/gitlab pages
help    - this help text
cli usage examples:
# production build
NODE_ENV=production mspg clean build zip

# development (build files, watch for changes, and serve them on localhost:3000)
mspg build serve watch
example app

a minimal example app is in the example directory of this repository, using config.js from the root directory

example app on github.io

the example app is published to the gh-pages branch. it is hosted @ https://mspg.github.io/core

using html/css/javascript transpilation

writing transpilers for any kind of toolchain is pretty easy, just have a look at the examples below to get started if you want to use another toolchain. every transpiler also includes a minimal example project in the example directory.

html

both html toolchains below follow the same rules:

  • every *.html file in the src/ directory is a page and gets transpiled to public/

  • every includes/html/*.extension file is an include file and can be included using /filename.extension

  • every includes/html/*.extension file can also be a template file. using extend you can reuse a html template in both pug and posthtml.

  • pug

  • posthtml

css
js

About

magic static page generator core

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published