I'm using node.js and the "less" compiler middleware:
app.configure(function() {
// ...
app.use(express.compiler({ src: __dirname + '/public', enable: ['less'] }))
// ...
})
Now i've got a faulty .less
-file, but I can't find any docs on how to get the error message.
The page I receive is this:
<html>
<head>
<title>[object Object]</title>
<style>
/* css stuff */
</style>
</head>
<body>
<div id="wrapper">
<h1>Connect</h1>
<h2><em>500</em> [object Object]</h2>
<ul id="stacktrace"></ul>
</div>
</body>
</html>
So that's not helpful. Anybody got an idea?
Ah, ok, got it. The trick is to leave away the development errorHandler
It seems to swallow calls to app.error, so now this works:
This shows the correct error instead of [object Object]