Be An Expert Xamarin Outdoorsman with the Ultimate Xamarin Toolchain

By: Vince Bullinger

ThatConference

August 9th, 2016

About Me

  • Vince Bullinger (“vbullinger” everywhere)
  • Live in St. Paul
  • WPI grad (‘04)
  • Been a consultant/developer since 2005
  • Always looking to improve skills

About Me

Married: 5/08

Zina: 7/4/11
Felix: 7/8/14

Leo: 1/17/16

Agenda

  • 30,000 ft overview of Xamarin
  • Stuff you should already know
    • PCLs, SAPs, Xamarin.Forms
  • Advanced Xamarin tools
    • HockeyApp, TestCloud, Profiler, App Services...
  • Third party tools
    • Components, Gorilla Player, Azure Marketplace...

Before We Get Started...

  • We will cover a lot of topics
  • We’re going over each step of development
  • We’re focusing on rapid development
  • There won’t be time for deep dives
  • We may spend time going over things you already know
  • You might want me to spend more time on some things
    • Too bad
  • I am by no means an expert on everything discussed...

Xamarin Overview

Silo Approach versus Xamarin’s approach

Source: adapted from Xamarin.com

Basics

  • PCLs
  • SAPs
  • Xamarin.Forms

Shared Asset Projects (SAPs)

  • Project of C# files containing cross-platform logic
  • Compiled into each platform-specific project
  • Use conditional compilation for platform-specific logic

#if __ANDROID__

// Android-specific code

#endif

#if __IOS__

// iOS-specific code

#endif

Portable Class Libraries (PCLs)

  • List target devices
    • Android, iOS, UWP, Silverlight
    • Selections filter assemblies

Cross Platform UIs? No Way!

Miguel de Icaza, 4/3/14

Cross Platform UIs? Great Idea!

  • Xamarin.Forms announced on 5/28/14
  • Cross-platform UIs…
    • C# or XAML
  • Best for apps w/normal UX requirements
  • Not great for apps with:
    • Advanced gestures
    • Animations
    • Design
    • Major security concerns...

Advanced Xamarin Tools

  • HockeyApp
  • TestCloud
  • Profiler
  • App Services
  • Workbooks

HockeyApp

  • Crash reporting, feedback, metrics, in-app updates
  • Good for beta testing
    • Add devices
    • Push builds via TFS or VSTS
  • Demo

TestCloud

  • Automated UI acceptance tests
  • Can test on many devices
  • Cloud-based
  • Uses Xamarin.UITest framework
    • Uses NUnit
    • APIs to execute UI interactions app.Tap("myButton")
  • Demo

Profiler

  • Collects information about apps
  • Find memory leaks
    • How is memory used and when
  • Resolve performance bottlenecks
    • See where app is grinding
  • Demo

App Services

  • Platform-as-a-Service from Azure for web and mobile
  • Azure SQL db
  • API generation
  • Authentication/authorization
  • Push notifications
  • Job processing
  • Way more...
  • Demo

Source: Microsoft

Workbooks

  • Live coding
  • Not real apps
  • Standalone
  • Playing around
  • Testing small things
  • Demo

Third-Party Tools

  • Components
  • Gorilla Player
  • Code obfuscators
  • More?

Gorilla Player

  • Live reload of XAML changes in Xamarin.Forms
  • On simulators, emulators, devices, etc.
  • Demo

Code Obfuscators

  • Code Fort
  • Crypto Obfuscator
  • Babelfor.net

More?

  • There are plenty
  • In my experience?
    • Broken
    • Xamarin/Microsoft stomped them
  • Azure Marketplace
    • It’s a thing
    • Not exciting

References