ASP.Net Developers, it is time to change your attitude towards JavaScript. I know you hate it. I used to hate it too. But I’ve come to terms with JavaScript and now actually quite like it! It isn’t my favorite language but I’ve been working hard to understand this important client side technology.

Please don’t be offended by this post. I know I have lumped all ASP.Net developers into one category here. I know many of you are in the same place as I am, moving quickly towards understanding Javascript. I am, however, speaking to a large group of .Net web developers who have not yet started their journey. You know who you are.

I’m a C# MVP and, prior to this past summer, I spent 3 years doing Silverlight development. I truly believe that Microsoft was on to something with the concept of Silverlight. Like many developers, with regard to client side web development, I knew there had to be a better way to do things than JavaScript. Silverlight was a great attempt. It wasn’t perfect but the concept was good. Heck, I thought that anything that saved me from JavaScript was a good thing. I don’t care what anyone says, JavaScript is not the best solution to client side programing. I think we could have had better. Silverlight was a good try but people didn’t embrace it for various reasons (I won’t get into that in this post). Well here we are now and Silverlight is pretty much toast. It seems like Microsoft has thrown in the towel and isn’t trying to replace JavaScript and I doubt anyone else will pick up that fight.

For the past 8 months or so, I’ve been back doing “traditional” web development. I’m quite happy to be in the world of asp.net MVC with HTML, JavaScript, and CSS. In the past few years, a lot has changed. Three and a half years go, when I last did this sort of work as the main part of my job, jQuery was gaining a lot of traction and was becoming widely accepted. But not like it is today. Today, many developers incorrectly use the words JavaScript and jQuery interchangeably (which is actually quite annoying). And as great as jQuery is, there are a ton of other great JavaScript libraries to help us developers. Patterns like MVVM and SPA have gotten quite popular. And I’ve learned that there are some other great patterns that can be applied to JavaScript development that can make the experience much better, especially for a pattern-happy OO developer like me. So I have been reading up on and practicing using closures, the revealing module pattern, prototypes, MVVM, dependency injection, and more. And I haven’t even started with TypeScript which looks very interesting, to say the least. And I should also mention that products like Visual Studio (and many plugins too) have come a long way to finally embrace JavaScript and have started to treat it like a first class citizen.

In addition to the fact that doing client side development is much better these days thanks to frameworks and tooling, our users have come to expect a richer experience from web sites and applications. Users want web pages to be useable and responsive and, dare I say, “nice to use”. And so, fellow ASP.Net developers, the time for faking our way through JavaScript is over. I have put a lot of effort into learning more about JavaScript. I’ve started treating that part of my job as seriously as I do C#. I don’t expect that I’ll become some kind of JavaScript Ninja anytime soon, but I’ve realized that JavaScript enhanced UIs are an important part of my work. I’m giving JavaScript respect and I’ll expect other developers to do the same. No longer will I accept a job candidate’s dismissive answers about their knowledge of JavaScript. “Yeah, I can do a little JavaScript but I don’t like it” is no longer a valid answer to an interview question. JavaScript is an important aspect of our jobs as web developers and it isn’t going anywhere, at least not for a while.

I talk about this story a lot… few years ago in a team meeting the developers were complaining about their struggles in writing JavaScript which was becoming an important aspect of our web solution. Our manager, who is a really smart guy and still a friend of mine, asked a few questions that made a big impact on me. First he asked, “How many books have you guys read about C#?” The response varied across the team but we had all read a bunch of them. He followed that up with the knockout punch… “how many JavaScript books have you read?” The room was pretty quiet. Most of the group had read none. At least I had read one, but I was wasn’t much different than the group. JavaScript programming was part of our job but yet we didn’t take the time to learn it. And through my career I have found that most ASP.Net developer’s (myself included) experience with and towards JavaScript was pretty similar.

The age of treating JavaScript with disrespect is over. It’s a necessary part of our web solutions. And as I said earlier, the frameworks and tooling have gotten much better. So now is the time to learn it, embrace it, use it, and succeed with it.

3 thoughts on “It’s Time to Learn JavaScript

  1. Josh,

    Thanks for the insult. I am an asp.net dev and I embrace JS, which was the point of my post. So your comment obviously makes no sense. I’ve left your not-so-friendly comment in here because I am a fan of freedom of speech.

    In response… I think it’s interesting that you refer to the entire .Net framework as an “abstraction”. You obviously have no idea what you are talking about. Although to be fair, all modern programming languages are an abstraction. But I guess you program in binary? Regarding “asp.net postbackery” and “runat=server”, I’m not a fan much of that anyway. As far as ASP.Net MVC, I think it is a great framework that doesn’t force to me to do anything. I can use it for it’s many benefits and, if I want, I can still use client side frameworks, ajax, etc. Which is pretty much what I am doing these days.

    Thanks for reading!

    Reply
  2. I doubt that ASP.NET “devs” will embrace JS – they are just too dumb. NET is a great productivity abstraction that hides the details, but it is a honeypot for lousy programmers. They gravitated there because they couldnt hack it with any other toolset.

    With NodeJS on server side and EmberJS or AngularJS on client-side – what do you need ASP.NET postbackery for ? runat=”server” is web-cobol.
    ASPNET MVC was a nice prescriptive framework where you didnt have to think, but with responsive client side MVC JS frameworks that support binding & templating, and JQuery AJAX to REST calls – ASPNET MVC’s time has passed.

    Reply

Leave a reply

required

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>