1.0.2 • Published 10 years ago
spirit-paths v1.0.2
Spirit Paths
Summary
A file path Middleware for the Spirit Core static file generator.
Syntax
Install Spirit Core .
npm install spirit-core
Directory structure
- "test"
- "src"
- "dest"
var SpiritCore = require( "spirit-core" ) ;
var config = {
src : "src",
dest: "dest"
} ;
var spirit = new SpiritCore( "./test", config ) ;
var spiritData = spirit.getData( ) ;
console.log( "src %s, dest: %s", spiritData.src, spiritData.dest ) ;
Properties
spiritData.src
The absolute source path. Defaults to the root directory
spiritData.dest
The absolute destination path.
Defaults to the "rootPath/dest"
.
Configuration
The Middleware can take an optional two configurations
src
The relative source path.
dest
The relative destination path.
var spiritConfig = {
src: 'some/path/src',
dest:'some/path/dest'
} ;
Handmade in San Francisco California by Alex Ray