Tech in the 603, The Granite State Hacker

C# and WebAssembly

I’m honored to be able to post in Matt GrovesAnnual C# Advent again this year, and today… December 22nd, 2018, is my second year contributing to it.

Last year I talked about ways to unload the main UI thread in WPF/.NET apps.

This year, I want to call attention to the Uno Platform tools I’ve been evangelizing for the past six months or so. 

Silverlight is dead – Long Live Uno Platform!

To understand this perspective, we’ll need to walk through some key terms….

What is Silverlight?silverlight

For those who don’t know, about ten years ago, Silverlight was the way to write C# and XAML to run in the web browser. It required a plug-in to run, much like Adobe Flash Player. Unfortunately, Microsoft announced the…. untimely demise of Silverlight in 2012. Silverlight, to some extent, seemed a more catchy term than other related technology names, so Microsoft used Silverlight as the name for mobile platforms that are also now depricated. As a result, it became almost synonymous with XAML.

What is XAML?

XAML, “eXtensible Application Markup Language” is the markup language behind a few great UI / UX layers in various Microsoft .NET-oid languages.  For those who’ve used it, it’s an addictively cool language family.  Using Visual Studio, Blend, and Adobe DX, you can create first-class UI.  With features like Storyboard animation, basic animation becomes child’s play. Composition makes fast, dynamic animations easy. Once you’ve gotten the basic idea of it, one finds themselves wanting to use it anywhere they can…  or at least that’s been my experience through WPF, Silverlight, Silverlight for Windows Phone, Silverlight for Windows Phone 8 / 8.1, Universal Windows Platform (UWP) and probably others.

The “code behind” XAML is typically C#, and historically .NET based.

What is Universal Windows Platform (UWP)?

UWP is the native platform of Windows 10.  It’s similar to classic .NET in a few ways.  First, UWP feels a lot like Windows Presentation Foundation (WPF) and .NET, being XAML and C# based, respectively.  It differs from classic .NET because it has a lot of fixes, both in terms of security and performance, that .NET can’t afford to apply for various reasons.  More simply put, .NET had some serious technical debt built up, so the easiest way to forgive that debt was to build a new platform based on the old languages.  Your XAML and C# skills are the same, but the namespaces and supporting framework libraries are different.

Don’t fret, though…  UWP runs natively on over 800 million devices (as of today, December 22nd, 2018), and that number continues to grow.  UWP is the native platform for all Windows 10 devices.  This means desktops, laptops, tablets, phones, HoloLenses, Xbox consoles, IoT embedded devices, and more. 

What is WebAssembly?webassembly

WebAssembly is a relatively new bytecode language specification… a virtual machine specification, similar to the Java Virtual Machine (JVM), that is fully supported by most modern major web browsers.  It allows near native performance in the same sandbox that javascript apps run in.  When you run javascript in a web page, the jit compiler in the browser converts the code into tokenized bytecode in order to execute it quicker.  WebAssembly improves on this significantly by pre-compiling the code.  Because the code is pre-complied, it doesn’t have to be sourced from javascript.  It can be compiled from just about any programming language.  Wasm, as it’s called, went from a specification just a few short years ago to being well supported in all major modern web browsers.

What is Uno Platform?uno platform

Uno Platform, for our purposes, is not really a new platform, but an extension to UWP. 

You write your UWP application for your Windows 10 devices the same way you always have.  Uno provides a mechanism to re-compile that UWP app to Web Assembly (and… by the way… using Xamarin tools, also to iOS… and also to Android!)

In a sense, Uno Platform is to UWP as Xamarin is (roughly) to classic .NET.

See the connection? 

Let’s do some math…

UWP = C# & XAML for Windows 10.  (800,000,000 devices)

Uno Platform += UWP for iOS (Millions more devices), Android (over a Billion devices), and WebAssembly (every modern major PC in the world)

Now factor in this…

.NET Core 3 += UWP for services

What does all that add up to? 

One skill set… 

UWP (C# & XAML) = FULL STACK, on all major platforms

From data access layer to REST API to UI canvas.

Wait a minute…  What about Xamarin?

Xamarin is the older way to do C# for cross platform / mobile.  

Coincidentally, just this past Thursday, Carl Barton, a Microsoft MVP for Xamarin presented the Xamarin Forms Challenge at the Windows Platform App Devs users group. The goal of the meetup was to demonstrate creating a simple app in C# and running it on as many platforms as we could in the hour.  He easily pushed ran the app on over a dozen platforms in the hour.

Uno Platform actually depends on Xamarin libraries to support iOS and Android. 

The main differences between Xamarin and Uno Platform are these:

  • Xamarin encourages you to use a Xamarin-specific dialect of XAML, including Xamarin Forms to express your cross platform UI.
  • If you already know & understand Microsoft’s UWP dialect of XAML, Uno Platform uses that dialect.
  • Xamarin enables you to produce binaries for dozens of different target platforms, reaching a billion or more devices.  These include .NET, UWP, iOS, Android, Tizen, Unity, ASP.NET, and many others.
  • Uno Platform only enables you to reach three additional binary output targets…  iOS, Android, and WebAssembly…. but WebAssembly can or likely will soon cover most of what Xamarin Forms covers.

I’ll leave it up to you which to choose, but for me, given the choice between Xamarin with several years of technical debt built up in a distinct dialect of XAML, and Uno Platform, using the fresher, native UWP dialect of XAML…  

Finally… 

Here’s the slides I presented most recently at the New England Microsoft Developers meetup in Burlington, Mass on December 6th (thanks again to Mathieu Filion of nventive for much of the content):

[office src=”https://onedrive.live.com/embed?cid=90A564D76FC99F8F&resid=90A564D76FC99F8F%211297452&authkey=AM6QZrb_6-9ltdE&em=2″ width=”402″ height=”327″]

Tech in the 603, The Granite State Hacker

Intro to Uno Platform

Uno’s free.  Uno is open-source.  Uno could seriously be the next significant disruption in mobile development.

Apologies that I neglected to hit on the conference call for the introductions.  We did get the bulk of the presentation recorded.

On the call:  Jerome Laban, Architect, and Francois Tanguay, CEO of nventive of Montreal, Quebec, Canada. Participants of the Windows Platform App Devs (including myself) were in the audience, asking questions.

To make up for the intro missed in the call, let me begin with the elephant in the room…

What’s “wrong” with Xamarin?

The relatively well known Microsoft tool set called Xamarin enables developers to write a dialect of C# and Xaml to target a variety of platforms including Windows, Windows Mobile, iOS, Android, MacOS and others.

For that reason, Xamarin’s currently a top choice for mobile developers around the world. Xamarin enables developers to target billions of devices.

The problem Xamarin presents is that Xamarin has become its own distinct dialect of .NET-based development.  Xamarin has its own distinct presentation layer called Xamarin Forms. Xamarin Forms as an employee skill set is not the same as a classic Windows developer set.  It’s not exactly the same as a Windows 10 developer skill set.  It’s a different platform, and requires developers that understand it.

Uno Platform reduces the skillset burden in this problem by converging the main skill set on Windows 10 development. Developers with an appreciation for the future of Windows development will definitely appreciate Uno Platform.

Windows Universal Platform (UWP) targets ALL flavors of Windows 10, including some unexpected ones, like Xbox One, and IoT devices running Windows 10 IoT Core.

Uno bridges UWP to iOS, Android, Web Assembly (Wasm), on top of Windows 10. This targets a huge and rapidly growing range of devices… (currently approaching around 3 BILLION… and that might be a low estimate.)

I’d embed the video, but Blogger’s giving me a hard time with the iframe-based embed code… please click this

Link to the video:

Intro to Uno Platform Skype conference recording.

The meetup:
Granite State Windows Platform App Devs
https://www.meetup.com/Granite-State-NH-WPDev/events/251284215/

Uno Platform’s site:
http://platform.uno

Tech in the 603, The Granite State Hacker

Locking Resources in C# for Read/Write Concurrency

In a previous project, I became a big fan of System.Threading.ReaderWriterLockSlim.  It was an excellent way to guard a resource against concurrency in a relatively flexible manner.  

C# has a lock(object) {} syntax for simple concurrency locks, but what if you have a resource that can sometimes be used concurrently, and other times, exclusively?

Enter System.Threading.ReaderWriterLockSlim.  This has a few handy methods on it for guarding code on a non-exclusive (Read) and exclusive (Write) mode, with an upgradeable lock, as well, so you don’t have to release a read lock in order to upgrade it.

This source works just as well in .NET as UWP.

I commented the code enough to try to make it so that someone familiar with ReaderWriterLockSlim and using(IDisposable){} would understand the rest, so without further ado…

https://gist.github.com/GraniteStateHacker/e608eecce2cb3dba0dbf4363b00e941f.js

Tech in the 603, The Granite State Hacker

Live Process Migration

For years now, I’ve been watching Microsoft Windows evolve.  From a bit of a distance I’ve been watching the bigger picture unfold, and a number of details have led me to speculate on a particular feature that I think could be the next big thing in technology….   Live process migration.  

This is not the first time I’ve mused about the possibility… [A big feature I’d love to see in Windows 11] it’s just that as I work with tools across the spectrum of Microsoft’s tool chest, I’ve realized there are a few pieces I hadn’t really connected before, but they’re definitely a part of it.

What is live process migration?  Folks who work with virtual machines on a regular basis are often familiar with a fancy feature / operation known as live virtual machine migration….  VMWare’s vSphere product refers to the capability as vMotion.  It’s the ability to re-target a virtual machine instance, while it’s running… to move it from one host to another.

In sci-fi pseudo psycho-babble meta physio-medical terms, this might be akin to transitioning a person’s consciousness from one body to another, while they’re awake…  kinda wild stuff.

As you can imagine, live VM migration is a heavy duty operation… the guest machine must stay in sync across two host computers during the transition in order to seamlessly operate. For the average user, it’s hard to imagine practical applications. 

That said, live process migration is no small feat either.  A lot of things have to be put in place in order for it to work… but the practical applications are much easier to spot. 

Imagine watching a movie on Netflix on your Xbox (or maybe even your Hololens), but it’s time to roll.   No problem, with a simple flick gesture, and without missing a beat, the running Netflix app transitions to your tablet (or your phone), and you’re off.   Then you get to your vehicle, and your vehicle has a smart technology based media system in it that your tablet hands off the process to.   It could work for any process, but live streaming media is an easy scenario.

From a technical perspective, there’s a bunch of things required to make this work, especially across whole different classes of hardware…  but these problems are rapidly being solved by the universal nature of Windows 10 and Azure.

Commonality required:

  • Global Identity (e.g. Windows Live)
  • Centralized Application Configuration
    • Windows 10 apps natively and seamlessly store configuration data in the cloud
  • Binary compatibility
    • Universal apps are one deployable package that runs on everything from embedded devices to large desktops and everything in between.
  • Inter-nodal process synchronization
    • Nothing exemplifies this better than the 1st class remote debugging operation  in Visual Studio.  You can run an app on a phone or device from your laptop, hit breakpoints, and manipulate runtime state (local variables) from the laptop and watch the device react in real time.
  • Handoff protocol
    • I’m sure it exists, but I don’t have a good word to describe this, but it’s probably based on something like SIP
  • Runtime device capability checking (the part that sparked this blog post).
Over the years, there have been a lot of “write once, run anywhere” coding schemes.  Most involve writing a program and having the compiler sort out what works on each type of hardware…. what you get is a different flavor of the program for different kinds of hardware.  In Windows 10, it’s different.  In Windows 10, the developer codes for different device capabilities, and the application checks for the required hardware at run time.  
While the UWP does an amazing job of abstracting away the details, it puts some burden on the hardware at runtime…  the app developer has to write code to check, anyway: hey, is there a hardware camera shutter button in this machine?  If yes, don’t put a soft camera shutter button on the screen, but now the app has to check the hardware every time it runs.
I struggled a bit trying to understand this latter point…  why would Microsoft want it to work that way?  Except for a few plug & play scenarios, it could be optimized away at application install time…  unless your process can move to a different host computer/phone/console/tablet/VR gear.
While I am (more recently) a Microsoft V/TSP working for BlueMetal, an Insight company, I have no inside information on this topic.  I’m just looking at what’s on the table right now.   We’re almost there already.  Yesterday, I showed my son how to save a document to OneDrive, and within moments, pick up his Windows 10 phone and start editing the same document on it.
In my mind, there’s little doubt that Microsoft has been working its way up to this since Windows Phone 7… the only question in my mind is how many of these tri-annual Windows 10 updates will it be before “App-V Motion”-style live process migration is a practical reality.
Tech in the 603, The Granite State Hacker

Apache Cordova and SharePoint Online / Office 365

The concept came from a good place, but at this point, the story is best described as “science experiment”, as I mentioned at SharePoint Saturday Boston 2015.  I was working on a cross-platform Apache Cordova project for Windows, Windows Phone and Android when the call for speakers hit.  I said “why not?” and I signed myself up to present it…

The good news is that the story’s not without some worth to someone exploring the idea of hooking into SharePoint from an Apache Cordova-based app. Tools that exist today at least assist in the process.

[office src=”https://onedrive.live.com/embed?cid=90A564D76FC99F8F&resid=90A564D76FC99F8F%21470742&authkey=AF2UYViSqPU21mw&em=2″ width=”402″ height=”327″]

The demo code is mostly about accessing files from your personal SharePoint profile document library (A.K.A. OneDrive for business) and indeed, the code is using file access code in addition to SharePoint connection.  The hardest work in a browser based app is to authenticate with Office 365, and this code does that, and then opens up to the rest of SharePoint…

[office src=”https://onedrive.live.com/embed?cid=90A564D76FC99F8F&resid=90A564D76FC99F8F%21470744&authkey=ABWELP8Z5xOqUSY” width=”98″ height=”120″]

Tech in the 603, The Granite State Hacker

A big feature I’d love to see in Windows 11

With all the announcements coming out of //Build, I’m pretty jazzed about what’s coming in Windows 10.   That doesn’t stop me from wishing there were one or two other scenarios Microsoft would get to… and at this point, I’ll have to hope to see them in something after Windows 10.

“App-V-Motion” running apps, migrating them across devices. 

Enable an app running on the phone or tablet or laptop or desktop to seamlessly transition from device to device.

Imagine it’s getting late in the day…  you have a long running process on your desktop that you need to babysit.  Poor timing, sure, but it happens far too often.   Now, rather than being tethered to your desk, you can transition the process to a mobile device, and simply take it with you.   Perhaps it’ll take longer to complete on the mobile device, so when you get home, you hand it back off to bigger iron. 

or, my other favorite scenario…  you’re watching your favorite movie, but it’s time to roll…. so you hand off the movie player app to your phone, and keep watching while you’re on the go, without missing a beat.

With cloud configuration & storage, this scenario is getting more and more feasible, but given where I’m seeing Windows 10, now, this could potentially be a 10.1 or 10.2 feature.

Tech in the 603, The Granite State Hacker

Apache Cordova and Windows Universal (8.1)

Thanks to everyone who made it out to the Granite State Windows Platform Users Group last night (April 16, 2015) to see my presentation on using Apache Cordova to create Windows Universal (8.1) “store apps”. 

I walked away feeling like I’d helped inspire everyone who attended…  even as an “intro” level presentation, the demos seemed to keep everyone engaged, asking questions, and prompting me to go “off-roading” to check out various features. 

We really had fun with it!

So while the best part of the presentation was the demos, the slides do have some great links in them.

[office src=”https://onedrive.live.com/embed?cid=90A564D76FC99F8F&resid=90A564D76FC99F8F%21370273&authkey=AKm8AYTLUY1iyG8&em=2&wdAr=1.7777777777777776″ width=”350″ height=”221″]
 
 

If you missed it, don’t worry too much…  I’ll keep this presentation dusted off & ready for upcoming events, as well…  I could imagine it fitting well into a Code Camp event or something akin to it in the coming year.  

Heck, feel free to reach out to me if you think this is something you’d like to know more about… I’m happy to have a chat about it.

Next month’s meeting is already scheduled…  we’re looking forward to Jim O’Neil coming to reprise his Boston Code Camp 23 presentation on Themes in Windows Universal (8.1).   Please join us!

Meetup:  http://www.meetup.com/Granite-State-NH-WPDev 



Tech in the 603, The Granite State Hacker

Data Persistence in Windows Universal (8.1) apps (Boston Code Camp 23)

Thanks to everyone who joined me for my Boston Code Camp 23 presentation.  Shuffling data around is a core responsibility of any serious computing platform.  Windows Universal really goes above and beyond the mundane call of duty with consistency and utility. It’s part of what makes the Windows client platform a true “cloud car”, especially with its Backup, Roaming Settings / Folders, and Roaming Password Vault capabilities as native functionality… all from the Windows.Storage namespace.

Here are

For the individual who asked what encryption level the Windows Password Vault functionality uses, I looked it up, and it’s 128bit AES encryption.  Stern stuff there.

Another question came up about app backups.  As I said in the presentation, the content of the Local storage is backed up automatically to the cloud by the OS.  (Isn’t that fantastic?!)

Likewise, as mentioned, the Temporary storage is excluded from backups.

One detail I missed however… the LocalCache storage area.  LocalCache is like Local except that it is not backed up.  LocalCache differs from Temporary storage in that the OS will not wipe it as it occasionally does the Temporary storage.  Next time I do this presentation, I’ll make sure to update it to discuss LocalCache.

Here’s a comparison of the storage options available to developers in the 8.1/universal platform. Note that each user on a device gets their own app-specific sandbox *and* OneDrive space for each installed app.

Type Availability Limits Settings hashtable Backed Up By OS Sync’d to all App / User / Devices by OS Encryption Wiped By OS if space is low Uri prefix Suggested use
Install Package Universal Static/ReadOnly Media from Install No No No Sandboxed No ms-appx:// Version specific static app media
Local Universal Available free storage Yes Yes No Sandboxed No ms-appdata:///local/ General
Local Cache Windows Phone Only Available free storage Yes No No Sandboxed No   Persistent cache
Temporary Universal Available free storage Yes No No Sandboxed Yes ms-appdata:///temp Semi-persistent cache
SD/Removable Universal Available free storage No No No None No   Removable/general
Roaming Universal 100k Yes (by virtue of roaming) Yes Cloud Partitioned No ms-appdata:///roaming Roaming settings
Password Vault Universal 100k (included in Roaming) Password-friendly structure (by virtue of roaming) Yes Cloud Partioned + 128bit AES No   Roaming credentials /OAuth tokens

I asked my stunt audience (the kids) later what my presentation had been about.  I was glad to know at least one of them had gotten it right. 

They were inspired, though, and that’s the important part. 

I hope you found inspiration in technology from both the day and maybe in some small part from my presentation.

Tech in the 603, The Granite State Hacker

Is Your Solution Delivery Strategy About to get Avalanched by Windows 10?

HoloLens took the spotlight when //build/ 2015 announced it had sold out in under an hour, but I can’t help but think at least as big a chunk of the excitement is around Windows 10 (or as we developers like to think of it, Windows Unified). As cool as HoloLens is, Windows 10 will most likely be landing in your lap long before HoloLens has images dancing in your living room. 

If you’re not already preparing for Windows 10, your solution delivery stack could be in for a shock from the client up. Microsoft is in the process of launching a re-boot of itself, and Windows 10 is the fulcrum of that effort. As usual, many of its changes are aimed at pulling developers in. If solution development has a place in your organization, this will likely impact you as well. 

“Mobile First / Cloud First” is, as always, the key phrase, and for a client OS… if it’s not for cloud devices…. give it a moment…  let that sink in…   Yes.  Windows 10 is an OS for mobile devices. Even if your device is a big heavy block of a workstation sitting near your monitor.  It will have the same mobile app store as phones and tablets, and it can be managed by the same Enterprise Mobile Device Manager (MDM).

Windows 8 was an introductory / transitional OS. With Windows 10, the transition matures.  Windows 10’s maturity is likely to make it far more palatable than Windows 8 was. (Keep in mind that Windows 8 is only a “failure” in terms of Microsoft’s other OS releases… Windows 8/8.1 has a bigger install base than some of the most “successful” of its non-Microsoft competitors. If Windows 10 becomes the hit many foresee it to be, it has potential to become the de facto standard platform to truly de-throne XP and even Windows 7.)

Windows 10 also adds a bit of a surprise, especially around browser technology.  Microsoft is tossing in to Windows 10 a whole new web browser (in addition to Internet Explorer) currently code-named Spartan. This new browser is intended to go after the consumer browser market, which IE has lost considerable ground in. I speculate that Spartan will be a breath of fresh air for consumers who feel IE’s bloat-related flaws collectively compels them to download Chrome or Firefox.

If you’re a web application developer who does more than a little HTML, on the other hand, you’re probably already groaning. You know what a pain browser compatibility is. (The browser was never intended to be a homogenous cross-everything platform, but that’s how a lot of web designers treat it, and they’ve shaped culture to expect it. Despite the best efforts of tools like jQuery and others to try homogenize, and trends like responsive to try to change the culture of presentation homogeny, web application developers get severely burned in the crossfire.  I’ve got more than a few scars to prove this, but you don’t have to look further than jQuery’s failed mechanisms for helping developers with these issues.    (First there was $.browser and $.browser.version, then $.support… then, “awe… heck… we give up, use Modernizr“.) /rant )

Spartan is a move that makes total sense, but it can’t help but add complexity to web application developers’ lives.  

In fact, in my mind, the long term net message is… there’s only one way to end browser pain… by getting out of web as a client platform. (Web services are the only part of the web worth salvaging.)

Microsoft has seen what platform diversification has done to its core OS business, and it’s not good. Developers need a consistent platform to deliver consistent solutions on, and that’s been a bigger part of Microsoft’s success over the years than even they seem to have realize.

So if web application development is becoming ever more complex in an already over complicated domain, how should one produce and deploy apps?

In a word:  native (aka mobile).

Windows 10 is a unifying platform, a “pentecostal” event to counter the “tower of babel” event of Windows platforms that have fractured into existence since the end of the .NET Compact Framework era. Where before development was requiring more and more effort to support PC, tablet, smartphone, wearable and even Xbox, Windows 10 has a unified SDK across all those platforms. For the first time ever, a .NET developer can build a single solution that runs in all those devices. There may be runtime differences between platforms that have to be ironed out, still, but not compile-time  (if(system.capability.phone) {} rather than #ifdef WINDOWS_PHONE_APP)

And think about it… what are the big reasons for web deployment?   Centralized management and centralized deployment.  Think back to MDMs and mobile app stores.

(Xamarin plays a roll in all this as well. Between Windows 10 and Xamarin, developers will be able to leverage a good chunk of their code base across all hardware, even non Microsoft platforms such as IOS and Android. This, too, is a breath of fresh air, because the cost of maintaining multiple code bases (and talent pools) is ever climbing. Xamarin will likely never be the 110% development experience that the latest .NET framework is, but neither was Silverlight for Windows Phone 7, yet one could do some fairly heavy lifting with it.)

Because Windows 10 is one platform that runs across form factors, it essentially means that any app written for Windows 10 is a mobile app. In that light, it means that Windows 10 is most likely to vault Windows into the top spot for mobile platforms by its projected install base. 

This on top of Microsoft’s recent “trickle up” theory of mobile market share growth, where Microsoft has been grabbing market share by targeting the feature phone market.  (This tactic has little effect in the US, where carrier subsidies nullify the low end to “$0”)  At some point Windows Phone will hit critical mass outside the US. Once that happens, even US developers will no longer be able to afford to ignore it.

Even if Microsoft is not contributing directly to your solution stack, Windows 10 and its biases have potential to culturally influence your solutions and solution delivery over the next decade.

Tech in the 603, The Granite State Hacker

AppStudio gotcha

Recently, I upgraded the Granite State (NH) SharePoint Users Group’s website from WSS 3 (MOSS 2007 generation) to SharePoint Foundation 2013.  The upgrade itself went as well as a 2007 to 2010 to 2013 upgrade could go, in general.

The only real “problem” I ran into was the Windows Phone app I wrote for the group years ago.  It was coming up with a 401 error trying to grab content from lists.asmx.  

I spent some time digging in the dirt, trying to resolve the 401, and hit a few common settings known to have an impact, but no good.  

Rather than struggle with it in my not so copious amounts of spare time, I decided to trash the old app, and build a new one with AppStudio.  

The app loads content from the #NHSPUG web site (http://granitestatesharepoint.org), mostly via RSS feeds.  I put a little extra effort into this.  Using AppStudio (http://appstudio.windows.com), I found a couple hours…  after that, I had not only a much prettier v3 of the Windows Phone app, but a Windows 8.1 (tablet style) publishing package as well.

One thing that caught me off guard though… the Gotcha:

The Windows 8.1 edition of the app wouldn’t load the content from the users group website. 

With some debugging, I found that attempts to load the content were coming up with “Unable to connect to the remote server. hresult=   -2146233088”.

Turns out the error had to do with the fact that I had not enabled Capability “Private Networks (Client & Server” in the Package.appxmanifest.   Ironically, the app works fine anywhere except where I was trying to test it:  on the same network as the content source server. So, to be fair, this is an environmental/configuration issue, not AppStudio, but it was worth mentioning, since my original assumption led me down that path. Maybe this will help someone else.

Oh… Here’s the Windows Phone app:
http://www.windowsphone.com/s?appid=8c1ce3ea-9ffd-46a0-80bd-6b45d1019b32

And here’s the Windows 8.1 (tablet style) app:
http://apps.microsoft.com/windows/app/granite-state-sharepoint-users/01ea0a83-f3af-4be6-abb0-268587072686

And here’s my moment of shame recording the incident and solution in the forums:
https://social.msdn.microsoft.com/Forums/windowsapps/en-US/be7b02cf-25d0-4aa2-8850-e0e2dce21fd2/appstudio-windows-81-apps-not-loading-external-content?forum=wpappstudio&prof=required