4 ms·
Wouldn't that conflict with possible future optional static typing? It's only Stage 1. I'm hoping it doesn't make it in its current form. Some good discussion i
by benatkin 3y ago
Wouldn't that conflict with possible future optional static typing? It's only Stage 1. I'm hoping it doesn't make it in its current form. Some good discussion in the issues, though: https://github.com/tc39/proposal-type-annotations/issues https://github.com/tc39/proposal-type-annotations/issues
- Someone1234 3y agoCan you explain why the two proposals would "conflict?" Seems like they're proposing the same thing to me.
- benatkin 3y agoIt would be hard to separate ignored ones from ones that would use a possible future optional static typing system. They would possibly have to use a different, uglier syntax.
- Someone1234 3y agoI'm not sure I follow. Both proposals are suggesting that browser's engines ignore the syntax completely to allow some other, external, process to check them. They use slightly different wording but are describing the same basic idea: This syntax will be ignored entirely and then optional/other process can use this area for whatever.
- benatkin 3y agoThere are other languages that have optional static typing that don't treat types as comments. JavaScript could evolve to add support for this.