3 ms·
I read, TypeScript code is sometimes faster, because it tends to favor monomorphic functions. Can I assume that V8 moved that gain to JS?
by k__ 6y ago
I read, TypeScript code is sometimes faster, because it tends to favor monomorphic functions.
Can I assume that V8 moved that gain to JS?
- exyi 6y agoEven in TypeScript optional parameters are very common, so I don't really think it's a JS specific optimization.
- toastal 6y agoIf you want to maintain compatibility with existing JavaScript, you kinda have to support the complexity of variadic functions and multiple return types; otherwise FFI would be required to use JavaScript. It seems this a convenience comprise TypeScript makes.