Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9096605
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T23:53:44+00:00 2026-06-16T23:53:44+00:00

I am creating a node.js app with Express and socket.io. I want to use

  • 0

I am creating a node.js app with Express and socket.io.
I want to use SASS and I see there is a npm package for it, what I don’t understand is how do I link between the SASS npm and the app and make it parse the SASS?

UPDATE:
I used SASS middleware https://github.com/andrew/node-sass installed it and included it the following way:

  sass = require('node-sass');


app.configure(function(){
  app.set('port', process.env.PORT || 3000);

  /* other stuff */

  sass.middleware({
    src: __dirname + '/public/stylesheets/sass',
    dest: __dirname + '/public/stylesheets',
    debug: true
  });
});

But it still doesn’t work

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T23:53:45+00:00Added an answer on June 16, 2026 at 11:53 pm

    You need to use the sass middleware, for example this one.

    Quoting from docs:

    var server = connect.createServer(
       sass.middleware({
           src: __dirname
           , dest: __dirname + '/public'
           , debug: true
        }),
       connect.static(__dirname + '/public')
    );
    

    in case of using express, just add:

     app.use(
         sass.middleware({
             src: __dirname + '/sass', //where the sass files are 
             dest: __dirname + '/public', //where css should go
             debug: true // obvious
         })
     );
    

    to your app.configure() call.

    Of course on production systems it’s a better idea to precompile sass to css.

    update

    In the example above the middleware will look for sass files in __dirname + '/sass/css'. Also by default it looks for files with .scss extension. There doesn’t seem to be an option to change the extension.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm creating an app that uses Rails to serve webpages and node.js/socket.io to facilitate
I am creating node.js app using express, everyauth and now.js. I have a server-side
I am creating a Node.js app on Heroku and have run into an issue.
Is there a .NET library for creating node graphs, one that lets you drag
I just started experimenting with Node.js Express and Mongoose by creating a simple blog
I was trying to create a node.js (express.js) app on a shared folder in
I'm creating an automated web app build process with node.js on windows. I'm trying
I have a Node.js app that should run forever and am creating a single
I am creating a Django app and want to have visualizations of a social
I am trying to understand what is the right tools for creating an app

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.