Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Typescript file reader #118

Closed
SirDarquan opened this issue Jun 3, 2015 · 6 comments
Closed

Typescript file reader #118

SirDarquan opened this issue Jun 3, 2015 · 6 comments

Comments

@SirDarquan
Copy link

So I noticed that in the angular/angular project, a Typescript parser was created to help the team create documentation from Typescript. Can you add that to this repo so we all can benefit?

@wesleycho
Copy link

@petebacondarwin so I took a look at this a couple of days ago, and noticed that currently the code is being read and then parsed directly from a string, whereas it does not appear the TypeScript parser is exposed publicly except via reading in the file through TS itself. I also noticed that the version of dgeni consumed by the Angular 2 repository is quite different from this one, and has support for TS baked in via a refactor of the parsing mechanism.

What are the thoughts on a proper solution for this situation? It would appear that a refactor here is necessary, but it may not match the state of dgeni from Angular 2, and I am unsure if the changes present in the Angular 2 repository will be backported here. I need some guidance here.

@petebacondarwin
Copy link
Contributor

The version of dgeni is the same, I believe. The difference is that in Angular 2 we are not bothering to use a file reader to read in the code, since the typescript library does that for us.

@petebacondarwin
Copy link
Contributor

This file - https://github.com/angular/angular/blob/master/docs/dgeni-package/processors/readTypeScriptModules.js - is reading the code files and generating new docs for each export.

@davidreher
Copy link
Contributor

@petebacondarwin Are there any plans for including the typescript package in dgeni-packages? Shall I submit a PR?

@petebacondarwin
Copy link
Contributor

@davidreher - that would be great if you wanted to make a PR - we need to make sure that the version that goes into dgeni-packages is:

  • independent of the Angular 2 project - i.e. doesn't have any funny special features that are only suited for the Angular 2 doc generation
  • can still be used in the Angular 2 project, without modification. There is little point in pulling it out if we then have to maintain a separate version for that project.

@davidreher davidreher mentioned this issue Jan 28, 2016
4 tasks
@petebacondarwin
Copy link
Contributor

We now have TypeScript support as of 3e07ade

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants