jscs-dev / node-jscs

:arrow_heading_up: JavaScript Code Style checker (unmaintained)
https://jscs-dev.github.io
MIT License
4.96k stars 513 forks source link

validateQuoteMarks - error is pointing somewhere in the middle of the string #2223

Closed hzoo closed 8 years ago

hzoo commented 8 years ago

Probably not intentional?

validateQuoteMarks: Invalid quote mark found at lib/config/configuration.js :
   380 |
   381 |Configuration.prototype._errorOnRemovedOptions = function(config) {
   382 |    var errors = ["Config values to remove in 3.0:"];
-------------------------------------------^
   383 |
   384 |    if (config.hasOwnProperty('esprima')) {
mdevils commented 8 years ago

You think it's a bug?

hzoo commented 8 years ago

@zxqfox brought it up - it could be. I guess it depends 😄. It would be cool if the error reporter could give multiple locs - like start/end for a string

qfox commented 8 years ago

It points to the space at the moment 😺. And definitely looks like a bug.

markelog commented 8 years ago

Well it isn't one, it is by design, we can add exception for such rule though, since it is looks weird yeah :)