Ignore the hype when writing JavaScript
For quite some time I felt ashamed for writing JavaScript because it was one of these languages all these kids wrote. In some of the circles I belonged to, you weren’t considered a programmer when JavaScript as one of the languages you write most of your code in (as if you would write PHP). But that was years ago.
Running away from JavaScript
So I headed off and learned a lot of nice languages such as Python and C++14/17. I also looked into sweet languages such as Rust and J just to name some. I loved it! But it was my destiny to come back to this language called JavaScript which I learned to hate.
When I returned to JavaScript
everything was different ES6 came up slowly, Node.js developed a lot since then, ReactJS was a hyped thing now — AngularJS and EmberJS grew a lot and all these new web technologies were suddenly out there. I mean CoffeScript felt old but Dart and TypeScript???. The community was so huge now and there were so many new projects out there. I was overwhelmed but only for a short time. I wasn’t a fan of any of these projects just like I wasn’t a fan of jQuery the last couple years at my time at JavaScript.
Step back and take another look
The concept of virtual DOM wasn’t new especially back in the day people were pretty annoyed by the speed of the DOM but nearly no one used a special library to help’em. The main reason I didn’t like jQuery back in the day was that I just didn’t like all these weird run-time checks and I didn’t want to clutter pages with libraries of which I’d only use 3% of the features.
So back in the day I had already switched over to the Google Closure Tools and I figured out pretty quickly that using libraries via externs using the Closure Compiler is a mess.
Refactoring ReactJS
So when I first saw all the hype around ReactJS. I was like yeah sounds awesome but I don’t like how they do it — so I started to re-write the entire thing for the Closure Compiler. I literally spend a couple weeks on going through that source code and I must say that ReactJS source is a mess! I hated it. You see so much “optimized” code in there and you really feel how they tried really hard to get feature detection checks to run only once but in the end it’s just a mess. Total garbage was my conclusion and I was happy to find incremental-dom. Incremental DOM in my opinion is an optimistic approach. Still diffing the DOM but not building a virtual DOM because why not. The browsers will eventually figure out how to get DOM access really fast and the real issue is that the developer doesn’t even know what he wants to update. That’s why we use this weird stuff in the first place!
AngularJS and others
The philosophy of most developers nowadays is in my opinion: “It’s 2016 everyone has a modern browser with JavaScript enabled so why should we care about users without JavaScript or older browsers?”
I actually know quite a lot of great hackers who disabled JavaScript in their browser and I respect their decision. When I was first talking with a guy about AngularJS I was shocked. Because in AngularJS you literally send these double braces for data binding and if someone doesn’t have JavaScript he’ll see those instead of anything useful. So because your Website doesn’t work without JavaScript anymore people even defined a new term for it and now call it “web app”. At least that’s what I thought the term stood for when it was first introduced to me and that just makes me worry.
Transpile to JavaScript
That option was available for ages. But I never was a fan of it. If I want to produce JavaScript code I want to write JavaScript and not CoffeeScript, TypeScript, Dart or any other language. (Don’t get me wrong here I’m actually a fan of emscripten because it makes sense).
But Babel for example is a great thing! Because you actually still write JavaScript but at the same time care about browsers and I think there’s even a tree shaking plugin for Babel (I mean it’s not great but it at least does something). Incremental DOM uses Babel so that you then can use the library directly as a module for the compilation with the Google Closure Tools, I mean that’s just great work!
Conclusion
So while I’m sitting back here not taking 99% of the job offers because of the technology they want me to use and probably even being the only one who’s still a little suspicious about the Polymer Project.
I allow you guys to go with the hype and “get things done” in an “economically feasible way”. Meanwhile I enjoy to live with old-school tools looking forward to a bright future.