-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Multiple __extends
output across various files
#1350
Comments
This has been a common request and we already had the notion of not emitting |
Thanks for the feedback. Cheers |
This has been covered in #2901 |
Closed
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Given the following files
And the following command, either
--module
flag will work for this exampleThe following files are output
As you can see, a lot of repetition of the
__extends
functions starts to appear when working with a larger codebase.My question is this, would the TypeScript team be open to a flag that can be passed to
tsc
that will generate something lke the followingThis will be an option that will need to be bought into by the user executing the
tsc
command. This is not a suggestion to refactor the existing--module
flag, maybe--customExports
.The onus would then be on the develop to wire up an
__extends
module themselves. A module that could be reworked to suit there needs should they see fit. See #1193. Some boilerplate could be generated and printed tostdout
similar to the way that behat squawks about missing test snippets.The advantage of this solution is the obvious reduction in repetitive code, as well allowing customisation of the
__extends
function, and helping teams hit that elusive 100% coverage.Some references
https://typescript.codeplex.com/workitem/2002
http://stackoverflow.com/questions/22155106
The text was updated successfully, but these errors were encountered: