I love Xamarin. There, I said it! It is an incredibly bright beacon in the mobile landscape, and one that I believe will lead our industry to new and exciting avenues.
So, what is it? Xamarin is mobile application development platform, specializing in that same pitch you’ve heard one hundred times before, the golden, radiant, trumpet blare inducing, cross-platform codebase enabler. Except this time, they hype is real.
A few years back I stumbled across this curious piece of tooling, way back before Xamarin Studio was a thing. I’d already been wholly unimpressed by the PhoneGaps and Titaniums of the day, and was not expecting very much. What I found though, while not even remotely ready for primetime, was the start of something incredible.
What Xamarin manages to get right, what everyone else manages to get so wrong, is that their final product doesn’t just look like a native application, doesn’t just feel like a native application, but indeed, it IS a native application. And that’s a pretty huge deal.
Now, back in the day Xamarin was not a pleasant thing to work with, to be completely honest. You had the option of doing file linking, or using conditional compilation, to share your code. While the premise was great, the execution was lacking. But then, something incredible came into play, and that something was the humble PCL.
A PCL is a Portable Class Library, and while I won’t bore you with the details (yet!), know that it allowed you to write C# code that was capable of targeting multiple different platforms, by leveraging their feature intersections, via Profiles. Now, we were able to have a real library project in our Solution, and not have to litter the file with
#ifdef and hurt our caveman brains juggling file linking. It was about this time that I began focusing every moment of my rare free time on learning Xamarin. I could tell it was a boat I didn’t want to miss.
Eventually the last piece of the puzzle came into play, Xamarin.Forms. This phenomenal toolkit allows you to write most of your UI code, once. No more having to mess with Storyboards and AXML files, just one and done. Plus you get all of the wonders that XAML brings to the table. Data Binding, Commands, oh my! It functions essentially like a UI PCL, targeting the intersections of the various platform UI components.
For example, a Forms ListView captures the idea of an iOS UITableView, an Android ListView, and so on. It is a convenient distillation that allows you to rapidly produce high quality user interfaces.
Then, in Spring 2014 I decided to enroll in the newly minted Xamarin University. I learned quite a bit of stuff there, the most valuable of which being the Forms related items, as they were hot off the press while I was enrolled. The instructors were always very friendly, and quick to answer every single question posed.
My journey concluded this past month, when I finally got around to completing their rather large competency exam. It was pretty brutal, 150 questions take over a few hour period, but I survived, and was rewarded with this shiny badge:
Isn’t it lovely? I’m quite proud of it!
Now, I was just kidding when I said my journey was over, it is very much just beginning. I’ve been lucky enough to work on a few Xamarin projects this past month with some extremely senior C# developers, and have come to realize I’m only just scratching the surface of what C#, MVVM, Xamarin, and all the other goodies have to offer.
I will be using this blog to chronicle all of the stuff I learn and encounter. Whether it’s a great library, a solid architectural approach, or a sneaky pitfall, I’ll be reporting back here. That said, I pride myself on being platform agnostic, so there will surely be tons of other stuff popping up here and there.