dbservestyl

0.0.5 • Public • Published

dbservestyl - Serve .styl files as .css

Example:
"use strict";
 
const dbservestyl = require('dbservestyl');
const express = require('express');
const path = require('path');
 
let app = new express();
 
app.use('/css', function(req, res, next) {
  let index = path.join(__dirname, "/www/css");
  let fn = dbservestyl(index);
 
  fn(req, res, next);
});
 
app.use('/', function(req, res, next) {
  let index = path.join(__dirname, "/www");
  let fn = express.static(index);
 
  fn(req, res, next);
});
 
app.listen(8080);

Package Sidebar

Install

npm i dbservestyl

Weekly Downloads

2

Version

0.0.5

License

ISC

Last publish

Collaborators

  • dbdii407