You can to use Express' static middleware to serve static files like (client-side) JS and CSS:
app.use(express.static());
That will, by default, try and find static files in ./public
(relative to the script you configure the middleware from):
yourproject/app.js <-- if configured here
yourproject/public/ <-- it will look here
If you use this in your HTML/template:
<link rel="stylesheet" type="text/css" href="/css/general.css" />
The middleware will find and (if found) serve ./public/css/general.css
.
If you want a setup where your CSS files are in the same directory as your application script, you can tell the middleware where to look for files by passing a directory as first argument:
app.use(express.static(__dirname));