3 ms·
How could trading the expressiveness of JS for the expressiveness of Java without the commensurate increase in performance be "So good it's ridiculous".
by richcollins 17y ago
How could trading the expressiveness of JS for the expressiveness of Java without the commensurate increase in performance be "So good it's ridiculous".
- donjaime_hn 17y agoYou clearly didn't RTFA. I'll give you my personal reasons for liking GWT in a few short bullets. 1. Better tooling - IDE refactoring when I need to change things. Red squigglies when I make a typo or reference something thats not there. A real debugger with breakpoints for finding bugs. Auto completion and auto style formatting so I dont have to type so goddamn much. 2. Compiler optimizations - Your code gets faster and smaller. Write maintainable code, have it turned into performant code. 3. API's and libraries - easy client server RPC, discoverable wrappers for the DOM APIs. Reuseable widgets that have predictable structure/side effects! 4. Maintainable code base - If you worked with more than 4 engineers on a non-trivial product, you would understand the appeal of a Java code base. UIBinder lets me not worry about CSS name collisions. I would go on, but you seem like a TLDR type of person, so it would probably be a waste of my time.
- mikedouglas 17y agoWas the personal attack at the end necessary?
- marcusestes 17y agoAgreed.
- donjaime_hn 17y agoProbably not. I sometimes get annoyed when people, faced with the choice of gaining some domain knowledge before forming an opinion, decide to instead just be loud about things they know little about. Personal attacks are lame though, even on the internet. Thanks for calling me out on it :). I apologize.
- madair 17y agoGood response to the question, which was clearly loaded
- richcollins 17y ago1. No reason you couldn't do this in JS (see Smalltalk) 2. The new JS VMs do plenty of optimization 3. C has more libraries than Java. Lets use C for everything 4. Actually, there is a lot of evidence that maintainability is inversely related to the number of lines of code. The more lines, the more bugs. (I don't have time to find the studies. They are there if you Google them.) I did read the article. I just wasn't interested in writing a treatise on the subject. Just wanted to give a counter point.
- boucher 17y agoThe performance that GWT is able to get is impressive. There are all kinds of optimizations they can make because of the assumptions they have, especially that you will run the code through the compiler.
- pohl 17y agoWhy ask this forum when the article explores this in detail?
- mikedouglas 17y agoDoes it, really? Most of the optimizations mentioned in the article (compression/obfuscation, module system, yslow integration) or in these comments (debugging, refactoring, auto completion) are all available/possible in javascript alone. What tangible benefits require Java's type system?
- mmastrac 17y agoGuided code splitting and type tightening (with associated devirtualization) are serious optimizations that can't be done today in JS. GWT can guarantee the immutability of JS object shapes - something you can't do with bog-standard JS.