Coder Social home page Coder Social logo

Comments (9)

smikes avatar smikes commented on August 15, 2024

Seeing that I added the custom versions support to node-jslint I'm all for it.

I don't know if the edition-selection logic is clean enough to be re-usable. Let's try it and if I need to fix node-jslint to make it work with grunt-jslint, then I'll do that.

from grunt-jslint.

smikes avatar smikes commented on August 15, 2024

Looks pretty straightforward. I didn't write the initial version of node-jslint/lib/nodelint.js but it's very similar to the logic for loading jslint that's currently used in grunt-jslint.

The only issue I see is the explicit output to console if the 'edition' parameter is invalid, but since it's not a direct ref to console we can work around that -- if we need to use grunt's error reporting system -- by passing our own dummy object using nodelint.setConsole (which I added in order to do coverage testing). This testing business is pretty cool.

from grunt-jslint.

smikes avatar smikes commented on August 15, 2024

Added some code on branch try-node-lint-issue-36 --

  1. incremented version number
  2. I needed jscoverage and I don't have it globally installed. Added it as a devDependency.
  3. I made a first pass at using node-jslint/lib/nodelint to load the JSLINT object. I hardcoded the parameter 'latest' so it wouldn't change the lint behavior, because node-jslint still uses an older jslint as default; latest is 2013-09-22. Obviously hardcoding is not the answer, but for testing purposes.. what do you think?

from grunt-jslint.

stephenmathieson avatar stephenmathieson commented on August 15, 2024

LGTM.

FYI - I haven't ever used the jscoverage in npm, but visionmedia's port instead. I don't think the latter works on Windows though.

from grunt-jslint.

smikes avatar smikes commented on August 15, 2024

Pulled the existing changes into master. Looked at options a bit this morning, I think I see how to allow the user to ask for a specific edition, but I haven't written that code yet.

from grunt-jslint.

smikes avatar smikes commented on August 15, 2024

OK. implemented now, added tests. Bumped the version in package.json but have not yet done the npm publish.

from grunt-jslint.

smikes avatar smikes commented on August 15, 2024

Travis found lint errors; now fixed. I can't run the acceptance tests on windows, possibly a difference in the way child processes work? Or maybe because I don't have grunt set up globally in a way which the acceptance tests can find.

from grunt-jslint.

stephenmathieson avatar stephenmathieson commented on August 15, 2024

hmm.. yeah, spawn is weird on windows. we may want to refactor the tests to use win-spawn.

go ahead and push to npm if you like :)

from grunt-jslint.

smikes avatar smikes commented on August 15, 2024

OK. Pushing.

from grunt-jslint.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.