Sitelet https://github.com/nodejs/node/issues/1253
Skip to content

Switch ClosureLinter to other linter. #1253

Description

@yosuke-furukawa

I am watching this discussion, #1243 .
This discussion is not suitable for discuss linter tools.

I have an interest to switch closure-linter to others.

We could not write template string literal in our codes, because closure linter does not recognize new syntax like "". I guess closure linter dose not recognize arrow function =>and generator functionfunction*`.
I think this closure-linter is to be obstacle to change our code to ES6.

So I would like to switch closure-linter to other linters like eslint, jshint.
IMO, I know eslint supports ES6 syntax. http://eslint.org/blog/2014/11/es6-jsx-support/

If @iojs/collaborators agree with this issue, I will send a pull request for this.

Activity

  1. yosuke-furukawa commented on Mar 25, 2015

    @yosuke-furukawa
    MemberAuthor

    @chrisdickinson I guess you also have an interest to switch other linter. #1243 (comment)
    This work is great!

  2. added
    discussIssues opened for discussion and feedback.
    metaIssues and PRs related to the general management of the project.
    on Mar 25, 2015
  3. brendanashworth commented on Mar 25, 2015

    @brendanashworth
    Contributor

    +1. However, we have to decide whether we should be able to run the linter without building io.js; the closure linter was written in Python, while both jshint and eslint are in JavaScript.

  4. jbergstroem commented on Mar 25, 2015

    @jbergstroem
    Member

    I'd be ok with only being able to execute things like tests, benchmarks and qa tools after a build.

  5. chrisdickinson commented on Mar 25, 2015

    @chrisdickinson
    Contributor

    Yep, the previous status was that we'd be okay switching to eslint / javascript-based tools, since they run after the tests (and thus, we can assume we have at least one working iojs around).

    I lean towards eslint (or eslint+jscs), since it's got a pluggable rule system. I have a work in progress branch that switches things over, if anyone would like to take it over. The difficulty was striking a balance between leaning useful rules on and avoiding code churn.

  6. silverwind commented on Mar 25, 2015

    @silverwind
    Contributor

    eslint looks pretty flexible. One thing I'd like to avoid is wrapping code in exclusion rules like this:

    /* eslint-disable new-cap */
    DTRACE_HTTP_CLIENT_REQUEST(this, this.connection);
    COUNTER_HTTP_CLIENT_REQUEST();
    /* eslint-enable new-cap */

    The new-cap rule assumes that the any capitalized variable is a constructor. Maybe the 'pluggable' system would allow us to add special rules like for these DTRACE constants?

  7. yosuke-furukawa commented on May 9, 2015

    @yosuke-furukawa
    MemberAuthor

    Switched closure-linter to eslint! Thanks! f9dd34d 19ffb5c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    discussIssues opened for discussion and feedback.metaIssues and PRs related to the general management of the project.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions