Skip to content
This repository has been archived by the owner on Mar 2, 2018. It is now read-only.

alibaba-archive/dot-middleware

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

#doT Middleware for Connect

doT - middleware (adapted from the stylus middleware)

Installation

npm install --save dot-middleware

Usage

If you're using express, then put the following configuration to your app.

app.use(require('dot-middleware')({
    src: __dirname + '/public',
    compress: true,
    amd: true,
    debug: true
}));
app.use(express.static(path.join(__dirname, 'public')));

You can use .html as file extension as well as .dot by adding an options:

extension: 'html'

Warn

  • Make sure that you put your templates in a sperate directory named as 'templates'.

About

This is a connect middleware for dot.js.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published