Skip to content

Instantly share code, notes, and snippets.

@sskoopa
Created January 15, 2017 16:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sskoopa/70a74132c12f764229565429250fb472 to your computer and use it in GitHub Desktop.
Save sskoopa/70a74132c12f764229565429250fb472 to your computer and use it in GitHub Desktop.
Use node-sass-middleware in express
const express = require('express')
const sassMiddleware = require('node-sass-middleware')
const app = express()
app.use(sassMiddleware({
/* Options */
src: path.join(__dirname, '../public/scss'),
response: true,
debug: true,
outputStyle: 'compressed',
prefix: '/scss' // Where prefix is at <link rel="stylesheets" href="prefix/style.css"/>
}));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment