21 ms·
Check that your Node.js project is well written, secure and follow conventions
- robotkilla 12y agoInteresting library – I ran it on one of my projects which consists of JS compiled from literate coffeescript. The JS also has also been run through browserify and uglify. My code is tested using mocha (albeit lightly), passes lint tests and seems to have no issues pre or post compiling, however when I run check-build I receive 28 errors and 25 warnings. Here is a sample of check-build's output: line 4 col 448 Line is too long. line 4 col 22 Missing "use strict" statement. line 4 col 80 Expected '===' and instead saw '=='. line 4 col 99 Missing "use strict" statement. line 4 col 109 Expected '{' and instead saw 'return'. line 4 col 123 Missing "use strict" statement. line 4 col 124 Missing "use strict" statement. This seems to be directly related to using uglify – my guess is that I need to tweak the config file to fit my stack (I'm using the default example). edit - I already changed the config to match my directory structure and am running check-build on the compiled JS.
- kieranajp 12y agoline 4 col 80 Expected '===' and instead saw '=='. Think this one is due to coffeescript's `if var?` syntax, which compiles to a loose comparison.
- phpnode 12y agoyep, you can disable this warning using .jshintrc - http://www.jshint.com/docs/options/#eqnull http://www.jshint.com/docs/options/#eqnull
- fgribreau 12y agoIndeed, if no .jshintrc was present, check-build will fallback on https://github.com/FGRibreau/check-build/blob/master/defaults/.jshintrc https://github.com/FGRibreau/check-build/blob/master/default...
- robryk 12y agoWhat is meant by checking that the project is "secure" is checking dependencies against known security issues. While this is useful, this is completely different from what is advertised (I've expected some sort of a heuristic security anti-pattern detector).
- fgribreau 12y agoYou are absolutely right, if you have a better way of saying this (while still being short) be my guest!
- nailer 12y ago> I don't want to create/edit a new make/grunt/gulp file or whatever hype dev use these days. Make is from 1977, and is pretty rare for web developers. gulp was designed as a grunt replacement, anyone familiar with the former can learn the latter. I love jslint, I love checking for insecure npm modules, and the other things this module provides seem good too, but having a build system doesn't preclude any of those.
- davexunit 12y ago>Make is from 1977, and is pretty rare for web developers. Because web developers seem to be unfamiliar with software that has solved their problems decades ago in languages that aren't JavaScript.
- nailer 12y agoYes, web developers are generally unfamiliar with shell interspersed with Make. Not wanting two additional languages for your project is an excellent reason to use a tool that matches the rest of your project.
- davexunit 12y agoAny developer should know how to write basic shell scripts to glue things together. Not taking advantage of the excellent pre-existing unix systems tools is a huge mistake.
- tokenizerrr 12y agoThat becomes a problem if you also want to have your project to be buildable on Windows, and it seems silly to exclude one platform solely because your build process doesn't support it.
- davexunit 12y agoPlenty of software that uses make and other tools is buildable on Windows.
- oblio 12y agoIMO drop the gifs, especially the "mind blown" one. They're very annoying to watch while reading the documentation.