Click here to Skip to main content
Click here to Skip to main content

Wait Did You Say JavaScript?

By , 7 Aug 2012
 

This blog was originally posted here: Frank's World - Adventures in Windows 8: Wait Did You Say JavaScript?[^]

Also, check out our Windows 8 sponsored section.

In my previous post, I mentioned that “I tried JavaScript first.” You may have also noticed that I’ve been blogging more and more about JavaScript dev and less about about XAML.

You may be wondering why that is.

Earlier this year, a tweet caught my eye.

I’m not so vain to assume this tweet about me, but the criticism could apply.

Not so long ago I posted this and was a big anti-HTML5 voice.

When I posted it, I meant it as a jab at all the “web hipsters” who were trashing the plug in development model. I still believe that the best way to get pixel perfect replication across platforms and browsers is via plug-in technologies such as Flash and Silverlight.

That having been said: I had an epiphany late last year: for the most part pixel perfect accuracy isn’t that important. What really matters is the experience. Pixels are a means to an end.

Fear and Loathing in Anaheim

In the months leading up to the Build conference in Anaheim, there was a lot of panic in the streets of XAML-town.

Every publicly made comment about the Windows 8 developer story referenced HTML5 and nothing else. The web hipsters were gloating. It was hard being a Silverlight guy.

At the conference, of course, the XAML world didn’t end and there’s a great XAML developer story in Windows 8. Naturally, everything that runs in Windows 7 (WPF, Silverlight, WinForms) will continue to work in Windows 8 Desktop. So, the panic was all for nothing anyways.

After that sigh of relief came that my skills were still relevant, I realized that HTML and XAML are not worlds apart.

The two platforms are not two super powers staging an enormous Cold War on the web for the hearts and minds of developers.

Sometimes, we need to take a deep breath and step away to get perspective and I had that chance in Anaheim.

The more time I spent looking at what more modern HTML and unobtrusive JavasScript, the less I began to dislike it.

Really, what it boils down to is markup and code: HTML and XAML are both markup syntaxes and JavaScript is just code, albeit kind of quirky.

I had closed my mind to any other option than the platform I had already chosen. I had been so deep in partisan developer politics, I lost sight of the big picture. 

This was the same sort of behavior I’ve railed against in the past.

The Moment I Saw that HTML5 Had Its Purpose

I’ll never forget the moment, it dawned on me that there “was something to this HTML5 thing.”

I don’t remember exactly where I was, but I do remember loading up a fellow developer evangelist’s blog. He had some silly star field animation on the header of his site and was a proponent of HTML5/JavaScript.

I had seen that before on my desktop and right mouse-clicked on the animation and noticed it wasn’t Silverlight or Flash.

I thought the animation was cute, but not much more than that.

But this time was different, I was looking at his site at the airport en route to Anaheim on my phone and the animation still worked.

I emailed my wife the link and had her try it on her Android phone. She said it worked.

Seeing that silly animation run the same on two different phone platforms as well as the desktop helped me connect the dots.

HTML5/JavaScript wasn’t the recycled 90s tech I thought it was: it was a universal cross platform/device development strategy.

Turning Point

While I was beginning to accept that HTML5 had its purposes, I was still a bit skeptical about it as a “real” development tool. I attended mostly the HTML-focused sessions at Build. I know XAML and figured I could pick that up pretty well on my own.

The more I saw, the more I was intrigued, but still felt that I’d probably do XAML dev.

The turning point came at a post-Build hackathon when a bug in the Developer Preview turned my project idea into mush. (It’s since been fixed)

Sitting there with nothing to do, I decided to re-write my DC Traffic phone app to JavaScript. In a couple of hours, I had something simple, but real.

Since then, I’ve spent a lot of time learning JavaScript and I’ve come to actually like, if not admire, the language.

It’s a strange little language, to be sure, but sometimes you can leverage that strangeness in your favor.

The Bottom Line

The truly marvelous thing about Windows 8 is how inclusive it is: you can write Metro style apps in C, C++, C#, VB or even JavaScript.

Better yet, you can even combine language use via Windows RT components.

That means you can leverage all your development team’s skills.

Got great C++ developers and awesome JavaScript/HTML/CSS ninjas? No problem: one group writes components and the other one the presentation layer.

At the end of the day, it doesn’t matter what language we code in. What matters is what we build and how well it fulfills a need.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

About the Author

FrankLavigne
United States United States
Member
No Biography provided

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
Hint: For improved responsiveness ensure Javascript is enabled and choose 'Normal' from the Layout dropdown and hit 'Update'.
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page   
GeneralMy vote of 1memberNarcissu54 Sep '12 - 3:49 
GeneralRe: My vote of 1memberFrankLavigne6 Sep '12 - 18:43 
QuestionJavaScript is a love hate affair; impartials are not as welcomemembermanchagnu4 Sep '12 - 3:08 
AnswerRe: JavaScript is a love hate affair; impartials are not as welcomememberFrankLavigne6 Sep '12 - 18:39 
GeneralMy vote of 5memberMagnus Gudmundsson14 Aug '12 - 21:45 
Nice article Smile | :)
GeneralRe: My vote of 5memberFrankLavigne15 Aug '12 - 11:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Permalink | Advertise | Privacy | Mobile
Web04 | 2.6.130516.1 | Last Updated 7 Aug 2012
Article Copyright 2012 by FrankLavigne
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid