3 ms·
Well for instance, Atom and VSCode have ~50ms (or ~49x) more input latency than editors written in C (source: https://pavelfatin.com/typing-with-pleasure/ https
by jackmott 10y ago
Well for instance, Atom and VSCode have ~50ms (or ~49x) more input latency than editors written in C (source: https://pavelfatin.com/typing-with-pleasure/ https://pavelfatin.com/typing-with-pleasure/ )
But maybe we are willing to accept 50x worse performance and higher memory requirements and slower startup time because the language is nice and guarantees correctness....Well no, it is javascript, not Haskell or Lisp. So, what is the win here? Why have we collectively decided javascript is a good tool for making applications for the desktop?
- Azkar 10y agoWell now when someone removes left pad from npm your whole terminal can break.
- joshmanders 10y agoNo it can't. After that whole fiasco npm has made it so packages once published cannot be removed after a 24 hour window without npm manually doing it on your behalf, that is to make sure this instance never does happen again.
- codemonkeymike 10y agoI can't agree more, There is no reason that editing text files would need a full web browser which is buggy and slow. Many of these javascript apps which are replacing native apps use 500mb of ram, at some point you will have 5-10 of these things churning memory and consuming battery life and cpu cycles. (Note Atom, HyperTerm, Chrome, Slack, and Kitematic is already 5 browser apps)
- johnfn 10y ago* We've decided to use JavaScript because the community is there. Go ahead and write an IDE in Haskell - have fun rewriting all the libraries that already exist in JavaScript and soliciting for open source contributions when a tiny fraction of all programmers can understand it. I love Haskell and lisp, but you have to face the facts. * TypeScript is actually a good language, and gives pretty darn good correctness guarantees. * Your benchmark does not test against VSCode, which is much faster than Atom.
- stymaar 10y ago> * TypeScript is actually a good language, and gives pretty darn good correctness guarantees. TypeScript's main focus is IDE tooling, not correctness. Here is an example on how generics are unsound in TypeScript: http://djcordhose.github.io/flow-vs-typescript/2016_hhjs.html#/21 http://djcordhose.github.io/flow-vs-typescript/2016_hhjs.htm... If you want to write JavaScript with a type system focused on soundness, you should give [flow](https://flowtype.org/ https://flowtype.org/) a try.
- johnfn 10y agoI don't think that anyone argued TypeScript is 100% sound, nor is that a meaningful goal to hit. I find TS to be a solid language that gives me reasonable confidence in my code. (The tooling is also great!)