Skip to content

yousifalraheem/browser-typescript-parser

 
 

Repository files navigation

node typescript parser

This package is a TypeScript and ECMAScript parser. It uses the underlying typescript parser to generate a more or less human readable AST out of .js or .ts files.

npm Commitizen friendly semantic-release codecov

How to use

You can use the parser with:

const parser = new TypescriptParser();

const parsed = await parser.parseSource(/* typescript source code as string */);

You can also parse multiple files at ones.

To use the declaration index (which is basically a list of symbols for your files) instantiate an index first and throw him some files.

After the parsing is done, you'll get an index with resolved exports and declarations.

Keep in mind, that the index'll only contain exported declarations.

Changelog

The changelog is generated by semantic release and is located under the release section.

Licence

This software is licenced under the MIT licence.

About

Parser for typescript (and javascript) files, that compiles those files and generates a human understandable AST.

Resources

License

Stars

Watchers

Forks

Sponsor this project

Packages

No packages published

Languages

  • TypeScript 99.2%
  • Other 0.8%