GithubHelp home page GithubHelp logo

kryndex / typescript-eslint-parser Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eslint/typescript-eslint-parser

0.0 1.0 0.0 1.04 MB

A TypeScript parser that produces output compatible with ESLint

License: Other

JavaScript 98.13% HTML 1.87%

typescript-eslint-parser's Introduction

TypeScript ESLint Parser (Experimental)

A parser that converts TypeScript into an ESTree-compatible form so it can be used in ESLint.

Important: This parser is not fully compatbile with all ESLint rules and plugins. Some rules will improperly mark source code as failing or not find problems where it should.

Supported TypeScript Version

We will always endeavor to support the latest stable version of TypeScript.

The version of TypeScript currently supported by this parser is ~2.3.2. This is reflected in the devDependency requirement within the package.json file, and it is what the tests will be run against. We have an open peerDependency requirement in order to allow for experimentation on newer/beta versions of TypeScript.

If you use a non-supported version of TypeScript, the parser will log a warning to the console.

Please ensure that you are using a supported version before submitting any issues/bug reports.

Known Issues

The following ESLint rules will fail on acceptable code:

  • no-undef #77
  • no-unused-vars #77
  • no-useless-constructor #77
  • space-infix-ops #224

The follow ESLint plugins have issues when used with this parser:

  • eslint-plugin-react #213

The following TypeScript syntax will cause rules to fail or ESLint v3 to crash:

  • Empty body functions
    • Abstract methods
    • Function overloading
    • Declared functions

Usage

Install:

npm i typescript-eslint-parser --save-dev

And in your ESLint configuration file:

"parser": "typescript-eslint-parser"

Help Wanted!

If you're familiar with TypeScript and ESLint, and you'd like to see this project progress, please consider contributing. We need people with a good knowledge of TypeScript to ensure this parser is useful.

Reporting Bugs

Please check the current list of open and known issues and ensure the bug has not been reported before. When creating a new issue provide as much information about your enviroment as possible. This includes:

  • ESLint Version
  • TypeScript version
  • TypeScript parser version
  • ESLint config or rules and plugins currently enabled

As well include a small code sample that can be used to reproduce the issue.

Contributing

Issues and pull requests will be triaged and responded to as quickly as possible. We operate under the ESLint Contributor Guidelines, so please be sure to read them before contributing. If you're not sure where to dig in, check out the issues.

Build Commands

  • npm test - run all linting and tests
  • npm run lint - run all linting

License

TypeScript ESLint Parser is licensed under a permissive BSD 2-clause license.

typescript-eslint-parser's People

Contributors

amilajack avatar azz avatar dannyfritz avatar despairblue avatar dtaub avatar flying-sheep avatar igorbek avatar jameshenry avatar nzakas avatar pajn avatar simenb avatar soda0289 avatar tomxtobin avatar weirdpattern avatar

Watchers

 avatar

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.