Skip to content

Typescript: Constant enums and namespaces are not supported. #5681

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

Closed
890f2151c2be69c51db72017546d00fd opened this issue Nov 2, 2018 · 3 comments

Comments

@890f2151c2be69c51db72017546d00fd

Can you provide little more info about this please?
Why they are not supported?
Do you plan support them later?

@christianchown
Copy link

They're not supported due to providing Typescript via Babel - https://blogs.msdn.microsoft.com/typescript/2018/08/27/typescript-and-babel-7/

Here's some thoughts on those features as they relate to CRA from the Typescript Project Manager: #4837 (comment)

@christianchown
Copy link

Ah, that comment is hidden due to the length of the thread in that PR. Here it is:

tspm

@Timer
Copy link
Contributor

Timer commented Nov 2, 2018

@milanholy83 they're not supported because they're limitations in the Babel implementation, though:

  1. Namespaces are deprecated. The TypeScript documentation is going to remove all references to them in examples and stop usage. In other words, you should not be using namespaces anymore.
  2. Const Enums are rarely needed and often misused.

@Timer Timer closed this as completed Nov 2, 2018
@lock lock bot locked and limited conversation to collaborators Jan 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants