Better error logging on the console
See original GitHub issueI’m wondering if it’s possible to get better Sass error reporting on the command line during a brunch watch
process?
Here’s my brunch-config:
SRC = 'source'
DIST = 'public'
BROWSERSUPPORT = ['last 2 versions','ie >= 9']
exports.config =
conventions:
ignored: [
/[\\/]_/,
/(^vendor\/phpunit)[\\/]/
]
paths:
public: DIST
watched: [
SRC
'vendor'
]
npm:
enabled: true
globals:
$: 'jquery'
jQuery: 'jquery'
_: 'underscore'
files:
javascripts:
joinTo:
'js/main.js': /^source/
'js/vendor.js': /^node_modules/
order:
before: [
'node_modules/jquery/dist/jquery.js'
]
stylesheets:
joinTo:
'css/main.css': SRC + '/styles/main.scss'
plugins:
babel:
presets: ['es2015']
sass:
options:
debug: 'comments'
mode: 'native'
includePaths: [
'node_modules/foundation-sites/scss'
'node_modules/motion-ui/src'
'node_modules/family.scss/source/src'
]
postcss:
processors: [
require('autoprefixer')(browsers: BROWSERSUPPORT)
]
fingerprint:
# Mapping file so your server can serve the right files
manifest: './public/assets.json'
publicRootPath: '/'
overrides:
production:
optimize: true
sourceMaps: false
plugins:
autoReload:
enabled: false
cleancss:
keepSpecialComments: 0
removeEmpty: true
uglify:
mangle: false
compress:
global_defs:
DEBUG: false
This is the current error logging I’m getting during a watch:
01 Nov 16:10:30 - error: Compiling of source/styles/main.scss failed.
With no further info… I’m using the 7-1 pattern which means I have a ton of Sass files—and I need to know which file is causing the error…
Have I uncovered a bug or is it user error?
Thanks!
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:12 (2 by maintainers)
Top Results From Across the Web
How to console.log an error with stack trace in node.js?
First, don't use console.log for logging. It's not horrible, but you can do much, much better. My favorite is to use morgan as...
Read more >12 Ways to Improve Your DevTools Console Logging
12 Ways to Improve Your DevTools Console Logging · 1. Output variable names with ES6 destructuring assignment · 2. Use appropriate log message...
Read more >JavaScript Error Logging - LogRocket
The best way to optimize JavaScript error logging systems is to use a tool like LogRocket. LogRocket automatically captures all JavaScript errors from...
Read more >Better console.logs - DEV Community
Here are a few ways you could make your logs a bit more visually informative, and interesting. Use console.error() for error logs.
Read more >Best Practices for Client-Side Logging and Error Handling in ...
In this article, we'll discussed methods of improving the default console logger, sending logs to a server, building error boundaries in ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hello @Slakinov, thanks for bringing this up. Will publish new patch version ASAP.
@shvaikalesh I’m on
brunch 2.9.1
andsass-brunch 2.9.0
and I’m still getting a crypticerror: Compiling of app/scss/core.scss failed.
Have I done something wrong?