4 min read

The Fragmentation of Web Application Development (aka Usability for Programmers)

I have recently felt the need to spend my free time getting back to my computer science and engineering roots i.e. my "maker" roots as Paul Graham would call them. Having spent the last four years working in the field of Product Management, I have remained very close to web application development, without actually developing any production level code myself. Instead I focused more on business processes, timeline and resource management, requirements analysis, prototyping, communications and usability.

It is that last focus - Usability - something of utmost importance in the products and services that we build for our users - that seems to have escaped us as we make our own tools of creation.

A Description of the Problem

In order to begin developing a web application of your own from scratch requires the knowledge of a minimum of four different development technologies:
  • A Database Query Language (SQL or otherwise)
  • An Application Layer Language of your choice (Perl, Python, Ruby, PHP, etc)
  • HTML
  • CSS
Developing a good web application on the other hand will probably require you to also learn Javascript or Ajax, and you are also most likely going to be using some sort of a framework whether it be Rails, Sinatra, CakePHP, or CodeIgniter. So that puts you at a total of six development technologies that you should be fluent in before you can deploy your own web application. This is before we even think about version control (Git / Subversion) and deployment tools and best practices.

Not the most usable solution is it?

Now dont get me wrong - I understand historically how the fragmentation of all these technologies occurred, I understand the difference between server side and scripting side languages, and I understand how HTML and CSS are the scaffolds that allow the internet to run even when the underlying architecture of applications are all programmed in many different languages.

But I would like to hope that in the future there is a world where all programming languages are created equal - and only a single language is required to develop an entire web application from start to finish. . Perhaps this is the reason that developing on the iPhone has been so popular: Apple's SDK allows you to develop an entire application with knowledge only of Objective-C (and the appropriate tools i.e. XCode and Interface Builder). Cocoa and any other library you may possibly use are all implemented in Objective-C, essentially giving programmers access to new functionality simply by learning a new library. Why is it that web development is lagging so far behind?

A Suggested Solution

I am not vain enough to think I know the perfect solution to this fragmentation in development languages and web technology, but I do have some ideas that would bring us closer to a utopian future:

The Model (i.e. Database and Business Layer Logic)

Rails has already shown us a great way to manage the creation of Databases, migrations, and even database relationships from within framework itself. It’s definitely not perfect, but its a good starting point. Alternatively XCode allows you to simply draw a database diagram (with the appropriate tables and relationships) and gives you ready to work with data structures while taking care of the rest. Both of these implementations allow the User (i.e. the developer) to remain in their language / IDE of choice, and utilize standard database theory (tables, relationships, primary keys, etc) to create a database that powers their application. Neither are perfect, but they are definitely a step in the right direction (i.e. either the visual or code creation of database tables and relationships).

The Controller

Most if not all object oriented languages support the concept of the controller layer with little if any abstraction. This is the one area where I dont think any significant change needs to occur. Notice I specifically mentioned OOP languages, because thats important for our next layer.

The View

At the end of the day I guess this is the layer that I have the most problem with. HTML tags, mixed with div's, and then hammered with PHP, Ruby, Python, Lisp, or whatever your language of choice is (and if your working with a group of programmers, it may be many of the above) - all and all it is a complete nightmare. Below is my suggested solution:
  • Programmers should never have to touch HTML. Our understanding of HTML standards is so ubiquitous that there should be language specific handlers for HTML tags i.e. in php:
  • echo.paragraph("this statement");
    Should automatically be translated to:
    <p> this statement</p>
    The same would apply to forms, links, headers, etc. Ideally this creates a view file that has no HTML at all - just application level language.
  • CSS is basically a configuration file with a well defined syntax. It seems to me that a simple configuration file (similar to the .plist's of XCode) would work just as well here. Defining div's would happen in this configuration file as well (and flows naturally within the OOP model as well as divs could exist perfectly as properties within an object).
The implementation of a language / IDE / framework that follows the essential guidelines outlined above would bring us one step closer to a world where the rapid development of web applications won't involve wrestling with technology, instead allowing developers to focus instead on programming concepts, best case practices, and cool ideas. Whether code is later compiled to be the understandable by the browsers of today and then uploaded to a server, or if the server dynamically compiles these files when requested by the browser is a technicality i'm currently not interested in (and has enough complexity to fuel separate blog post).

And i'm definitely not asking for a WYSIWYG editor - there are too many mediocre ones out there to count - what im brainstorming here is a complete end to end solution that utilizes a single development language to create an entire web application from scratch.

Maybe there is a technicality here that I am missing, having been away from web development for so long. Maybe what i'm suggesting has already been created and i'm not aware of it or its died in a technology graveyard somewhere. If you know of something that I have missed, or would like to chime in with better ideas to implement such a vision - please bring it to my attention in the comments.

In the meanwhile, I think i'll be heading over to XCode to play around with the iPhone SDK some more.

Edit:  Paul Graham has written a great article talking about a very similar concept while asking the question: what language will we be programming in 100 years?