Here’s my last minute appeal for donations for Extra Life. I’m going to be doing a 24 hour gaming marathon tomorrow (board games in my case) to raise money for Children’s Miracle Network Hospitals and specifically Cook Children’s Hospital. Cook Children’s is a non-profit hospital and money given will help purchase medicine, equipment, and provide treatment for the kids there.
I’ve made it past my original goal ($500), second goal ($750), and third goal ($1000), but that means nothing. Those are artificial numbers I used to encourage myself and others. If you can give, you should. I appreciate it and so do so many other people. Thank you!
Want to learn about how I think? No. No, you don’t; but I’m going to tell you anyway. Every day that goes by I add to this long list of stuff which interests me. It is neat from a technical standpoint, or it allows me to do something I didn’t know how to do or didn’t want to figure out for myself, etc.
Then I let those pieces rattle around in my head until something occurs to me about how I could combine them with what I already know to make something interesting.
So here’s a brain dump of all the stuff rattling around up there right now:
Browser Compatible Libraries
“That’s a mess of divergent crap you’ve got there John,” you might say; and you’d be right. But it’s kind of like looking at a huge pile of Legos. What do you see to build when you look?
By far, the most successful open source thing I’ve done in years is the project I called airquotes. It was my first project built using AngularJS and I published it early on to give others a chance to see something finished which had been built using it other than a to-do list.
Since then I’ve built some other projects outside of my day job using AngularJS and though not particularly profitable they are diverse (to say the least) and I’ve decided I’d like to open source them as well to see if they can help people.
The first up is PaperQuik (PaperQuik.com). It’s an app which asks a few simple questions and then generates a printable sheet of paper (lined, dot paper, graph paper, etc.) in the browser. Unlike most sites like this, it doesn’t just have a canned set of PDF files it dispenses, nor does it have a server process building them. Instead it uses the HTML5 canvas to draw an image of the paper and then helps you print that image.
The second project is ClearAndDraw (ClearAndDraw.com). It’s a simple webapp that I threw together in just a few evenings because I wanted to keep track of my cards and dice for the game Marvel Dicemasters: Avengers vs. X-Men. It’s not nearly as complicated as the paper generation in PaperQuik, but it does show real time filtering using AngularJS and it stores all of the information you give it in localStorage of the user’s browser so it doesn’t forget anything they enter.
I also took an evening and updated airquotes to the current version of AngularJS (1.2.25) and deployed it to a GitHub page so people can play with it without having to deploy it locally (like PaperQuik and ClearAndDraw).
This morning we encountered a MacBook that was not just dead, it was super-dead. It wouldn’t come on, even holding down the power button for ten seconds wasn’t sufficient to kill it and get it to start back up.
So I learned all new keystrokes to press to get out of this kind of situation that I’ve never encountered before:
If you still make notes, draw things, etc. then you still need paper and I’ve got a new project you might like. It allows you to create that paper and print it right from your browser. It’s only in an alpha form at the moment (which means not all of the features are finished yet), but you can already put it to good use and print out several kinds of paper in US Letter, US Letter (landscape orientation), US Legal, A4, A4 (landscape orientation), A5 sizes.
1. You’re constantly transporting state back and forth between client and server (and often neglecting to do so).
The next time you’re in GMail, notice something interesting about selecting emails. If you check several emails for a mass operation and then realize you’re not altogether sure about one email, so you click to read it, then you come back out to the list, the same emails are still checked. Now do the same test in an app written in any of the classic Java, PHP, Python, etc. frameworks. In those, when the user clicks on the email to view it:
In all likelihood it was just a link so all of the client-side state (the checked and unchecked checkboxes) is immediately discarded by the browser.
2. It’s slow, slow, and did I mention slow?
The development cycle itself is slower. I can throw up a temporary API using a variety of tools (or mock it client side using something like $httpBackend) and start work on the UI immediately. As I make each change I just have to refresh the browser to see my change in place. In fact, if I use tools like the Grunt server the browser refresh is automatically triggered when I save a changed file so I can just glance over at it and evaluate the results without leaving my code.
Most server side frameworks involve a compilation step of some type (for example, Java’s JSPs are translated to servlets and then those are compiled to a byte code for the VM). Thus I have a longer wait to view each change I make.
Users get tired of every thing they click upon meaning another trip to the server. If they just looked at that data a minute ago, it may well be in memory locally so showing it again is free. But if I have to go to the server again to get it re-rendered for re-display, I can get really old fast. I think we can all point to a site where we are frequently frustrated by the slow performance.
And why is it slow? Well, because it’s not just persisting data and performing queries on it, it’s also combining that data with HTML templates of some flavor to generate full pages and doing so over and over and over again. More work for the server means more servers needed, more time spent on performance tuning, etc.
3. It’s a more complicated programming model.
For many frameworks, lots of middle tier complexity can leak into the pages, making them way more complicated than HTML and thus much harder for designers (and programmers) to work on. I’ve seen this most often in frameworks where designers are expected not to use standard HTML. Instead they’re supposed to use perfect XML where every tag perfectly matches a closing tag and not a bracket is out of place, or they can’t use the <a>, <form>, <input>, etc. tags, instead each has some replacement which is supposed to be used which typically functions about 70% or so the same as the regular tag.
I loved this recent quote about JSF, a technology that I rejected at a previous employer because it was very clear that it was designed by committee and not extracted from real projects (like say Ruby on Rails):
4. Debugging is much more complicated.
Something as simple as how some HTML is rendering may require me to setup a debugger on a server on a remote machine because it is being generated from an intermediate file and data on the server.
Mine is not a real software rant, I wrote it tongue-in-cheek after reading one just this week which spun up a bunch of people. Like most of the others, I skipped gracefully past some problems:
I also skipped over the fact that there are browsers like older versions of IE where the debuggers are very poor and debugging can be just as painful client-side as it is for server-side.
Every framework that has achieved some level of popularity or notoriety has had its share of famous rants (Rails is a Ghetto, Node.js is stupid, and if you use it, so are you!, Why we left AngularJS which has since been renamed to 5 surprisingly painful things about client-side JS). Somebody doesn’t like the language, the framework, the community which goes with it and in frustration they vent. Sometimes they’re right about their complaints and sometimes they’re wrong, often it’s somewhere in between. Just relax and try to read it with an eye to whether the points being made are good ones and ignore the vitriol.