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

Feature request: deno tsc #3281

Closed
nayeemrmn opened this issue Nov 7, 2019 · 7 comments
Closed

Feature request: deno tsc #3281

nayeemrmn opened this issue Nov 7, 2019 · 7 comments

Comments

@nayeemrmn
Copy link
Collaborator

Expose the TypeScript compiler for CLI usage as a subcommand: deno tsc. I think this has a clearer story than the runtime APIs which have been suggested before.

@kitsonk I've assumed this is easier than #2927. Or is it dependent on the same issues?

@kitsonk
Copy link
Contributor

kitsonk commented Nov 7, 2019

How would this be effectively different from deno bundle or using tsc directly? And what would be the use case?

@nayeemrmn
Copy link
Collaborator Author

Really just being able to compile browser code without necessitating two TypeScript compilers and npm.

It's more of a "why not" to me I guess... this kind of thing would help justify the executable size on the surface.

@kitsonk
Copy link
Contributor

kitsonk commented Nov 7, 2019

#2927 Would seem more useful and less redundant in my opinion. Trying to replicate tsc doesn't really add any value. There is nothing unique and it would be a maintenance problem for no real value. I can certainly see value in having programmatic access to the built in TypeScript compiler though.

@nayeemrmn
Copy link
Collaborator Author

This isn't supposed to replace #2927 to be clear, but I get what you're saying. This would be redundant alongside good programmatic access.

I guess all I want is some way on the CLI of using deno's compiler on browser code.

If #2927 was used to implement a stripped down tsc in std which was aliased as deno tsc, that would satisfy this feature request. Of course that might feel too niche depending on how much usage it sees / how sparing we want to be about std subcommands - or it'll look perfectly appropriate either way!

@kitsonk
Copy link
Contributor

kitsonk commented Nov 7, 2019

I guess all I want is some way on the CLI of using deno's compiler on browser code.

That doesn't make sense, because generally the Deno compiler doesn't produce code that is usable in the browser, it doesn't do any real magic, it is the stuff it doesn't do that is really different from tsc. The only thing that makes sense is to do improve deno bundle so that it can run standalone or as an ES Module, which is in flight as part of #2475 and #3283.

@nayeemrmn
Copy link
Collaborator Author

Okay, I think I'd overestimated the amount of tsc's functionality that's included in Deno.

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

No branches or pull requests

3 participants
@kitsonk @nayeemrmn and others