Closed sgenoud closed 8 years ago
This sounds good to me, wonder if this'd be a decent time to explore the option of using 'standard' etc?
wonder if this'd be a decent time to explore the option of using 'standard' etc
I am not sure I understand want you mean, can you explain me?
We've changed our linting and code style a few times, if we used something like https://www.npmjs.com/package/standard (https://github.com/Flet/semistandard) we wouldn't have to maintain this side of the project.
If that's too drastic I'm :+1: for your approach though, see what everyone else thinks.
I do think it would be preferable to have a single tool to handle this, semistandard
may be ok although we could never use standard
and worried about semistandard
being similiarly obnoxious. Using eslint
directly also seems like a possibility.
eslint config file I use for pouchdb plugins, of which the code style is relatively similar I think: https://github.com/pouchdb/pouchdb-plugin-helper/blob/master/eslint (no support for ES6 import/export, see https://github.com/pouchdb/pouchdb-plugin-helper/blob/master/eslint-test for an example of that, but that one's too broad, because also other ES6 features are supported.)
What's wrong with just pinning our JSHint version where it is? Not sure there's always a burning need to "upgrade" every dependency, especially if they start going in a wildly different direction.
Nice!
Thanks @sgenoud for getting this going :+1:
The maintainer of JShint has decided to take it in a direction where it focuses on and do not implement coding style, see this SO answer (and the post it links to)
Why does that matter? Because pouchdb relies on jshint to enforce its coding style. Typically with the current version used the indent of 2 spaces does not show up in the posttest phase.
jshint proposes to use jscs for the task: http://jscs.info/overview, seems good enough to me (I spent a bit of time running it on the project: https://github.com/pouchdb/pouchdb/compare/master...sgenoud:adding-jscs I guess we should probably ignore the style for the comments (that adds lots of not that necessary changes).