New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

pug-static

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pug-static

Serve static Pug files from an Express server.

latest
Source
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

pug-static

Serve static Pug templates from an Express server.

Installing

It's an NPM package. You can just do the following.

npm install pug-static

Usage

Import it via node's require function.

var pugStatic = require('pug-static');

Then, you would simply add it as a used middleware when you configure your Express server.

var server = express();

// You can watch just about any folder to serve the static Pug files.
server.use(pugStatic("#{__dirname}/public/"));

Why?

This is a fork of jade-static, thanks shovon for the code! The project was renamed, so our team needed this.

What it does

  • Compiles JADE files on the fly.
  • Serves /path/index.pug when /path is requested.
  • Serves /path/index.pug when /path/index.html is requested.

What it doesn't do

  • No caching of any kind

License

MIT

Keywords

express

FAQs

Package last updated on 20 Jul 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts