Giter VIP home page Giter VIP logo

Comments (8)

lucacasonato avatar lucacasonato commented on May 19, 2024

I think we should start with all of the recommended rules in the possible errors section of eslint. These are lints that prevent runtime errors, so they are most useful. Those would be:

  • for-direction
  • getter-return
  • no-async-promise-executor
  • no-compare-neg-zero
  • no-cond-assign
  • no-constant-condition
  • no-control-regex
  • no-debugger
  • no-dupe-args
  • no-dupe-else-if
  • no-dupe-keys
  • no-duplicate-case
  • no-empty
  • no-empty-character-class
  • no-ex-assign
  • no-extra-boolean-cast
  • no-extra-semi
  • no-func-assign
  • no-import-assign
  • no-inner-declarations
  • no-invalid-regexp
  • no-irregular-whitespace
  • no-misleading-character-class
  • no-obj-calls
  • no-prototype-builtins
  • no-regex-spaces
  • no-setter-return
  • no-sparse-arrays
  • no-unexpected-multiline
  • no-unreachable
  • no-unsafe-finally
  • no-unsafe-negation
  • use-isnan
  • valid-typeof

Then later we should implement the possible errors recommended rules for typescript and then the remaining recommended eslint and typescript specific rules. It would be awesome if we could have support for eslint:recommended and @typescript-eslint/recommended out of the box.

Ideas?

from deno_lint.

bartlomieju avatar bartlomieju commented on May 19, 2024

I think we should start with all of the recommended rules in the possible errors section of eslint. These are lints that prevent runtime errors, so they are most useful. Those would be:

Then later we should implement the possible errors recommended rules for typescript and then the remaining recommended eslint and typescript specific rules. It would be awesome if we could have support for eslint:recommended and @typescript-eslint/recommended out of the box.

@lucacasonato thanks for compiling the list, presented approach seems to be reasonable.

Keep in mind I'm still iterating heavily on AST traversal and the AstTraverser will most likely be removed altogether in the near future.

from deno_lint.

bartlomieju avatar bartlomieju commented on May 19, 2024

Update: AstTraverser was replaced with swc_ecma_visit::Visit trait which serves the same purpose. I'm working on control flow analysis for more complex rules, but a lot of listed rules could now be implemented.

from deno_lint.

DomParfitt avatar DomParfitt commented on May 19, 2024

Hi @bartlomieju, are you looking for contributors for any of these rules? If so, I would be happy to have a look at one or more of them.

from deno_lint.

bartlomieju avatar bartlomieju commented on May 19, 2024

Hey @DomParfitt; this project hasn't received much attention in the past weeks due to release of Deno. There is still some core infrastructure missing, but if you can find a rule and implement it feel free to open a PR :) Keep in mind that scope analysis is not complete #21

from deno_lint.

sgtpep avatar sgtpep commented on May 19, 2024

How about no-unused-vars?

from deno_lint.

bartlomieju avatar bartlomieju commented on May 19, 2024

@sgtpep no-unused-vars requires scope analysis, which is WIP in #21

from deno_lint.

bartlomieju avatar bartlomieju commented on May 19, 2024

I've written down list of all recommended rules from ESLint in: #48

from deno_lint.

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.