Use Fingerprint Authentication In A NativeScript Angular Application

More than a year ago, before I started using Angular, I had written a tutorial on the topic of fingerprint authentication in a core NativeScript application. Since then, I’m doing almost all of my mobile development with Angular which means that the previous article deserves an upgrade.

I recently released a mobile application called Solar Flare for Cloudflare that protects your account with device level fingerprint authentication. We’re going to see how I included fingerprint authentication, sometimes referred to as touch id, in a NativeScript with Angular application.


Display Local Notifications In A NativeScript Application With Angular

A while back I wrote a tutorial that demonstrated how to use local notifications in a NativeScript Core project, also referred to as a vanilla NativeScript project. Since writing that tutorial I had received several requests to demonstrate the same in a NativeScript with Angular project.

If you’re unfamiliar, local notifications are scheduled notifications rather than notifications sent from a server. These notifications are useful when you need to trigger reminders in your application or based on events. For example, maybe you develop an iBeacon application and as you approach an iBeacon you want to receive a notification. This type of notification would be a local notification.

We’re going to see how to schedule and display notifications in Android and iOS using NativeScript and Angular.


Handle Google Play Services Conflicts In NativeScript Mobile Applications

I’ve been developing with NativeScript for a few years now, but only recently have I started working with the various services offered by Google Play. Using a single Google Play service such as Google Analytics works great, but as soon as you start adding more, you’ll start noticing Android conflicts during the build process.

Different plugins have different requirements on the underlying library versions. For example, one plugin might expect version 9, while another version 10, creating a versioning conflict.

We’re going to see how to get around these common problems that expand beyond NativeScript and into other development frameworks such as Apache Cordova and Ionic Framework.


Extend Legacy Java Android Applications With NativeScript And Angular

As some of you might know, before I started developing cross platform mobile applications using Ionic Framework and NativeScript, I was developing Android applications using nothing more than the Android SDK and Java. I still have one of my first applications, SQLTool, for sale in Google Play, and it was written with Java and Android. When building mobile applications, frameworks like NativeScript are incredibly attractive to web developers because they can use a common set of web design and development skills. However, NativeScript can be equally attractive to development teams writing Android applications with Java.

With NativeScript you can actually build a “polyglot” type application where parts are Java and parts are NativeScript with Angular. To be clear, I’m not talking about rewriting your Java application into modules wrapped in JavaScript like plugins. I’m saying that you can take your 100% Android with Java application and add Activities or Fragments built with NativeScript.

So why is this useful?

Imagine being on a small Android development team with more things to be done than there is time in the day. These Android developers would rather die than use a cross platform framework, but you have plenty of web developers floating around your company. In this scenario, the two worlds can collide and maybe the web developers can create lower (or higher) priority components for the Android application without having to convert the whole application to Android with Java or to NativeScript with Angular.


Tour Of Heroes As A NativeScript With Angular Android And iOS Application

When it comes to learning Angular, the go-to example is the Tour of Heroes tutorial that is found in the official Angular documentation.  This is a great tutorial because it covers a lot of topics, however, it is a web application tutorial.  What if we wanted to build a mobile application from it, or more specifically, a native mobile application with Android and iOS support?

We’re going to see how to build a Tour of Heroes inspired iOS and Android mobile application using Angular and NativeScript.


Build An Image Manager With NativeScript, Node.js, And The Minio Object Storage Cloud

When building a mobile application, there are often scenarios where you need to storage files remotely and when I say files, I don't mean database data.  For example, maybe you want to develop an image manager or photo storage solution like what Facebook and Instagram offer?  There are many solutions, for example you could store the files in your database as binary data, or you could store the files on the same server as your web application.  However, there are better options, for example, you could use an object storage solution to store files uploaded from your mobile application.  Popular object storage solutions include AWS S3 as well as the open source alternative Minio.

We're going to see how to leverage Minio to store images that have been uploaded from an Android and iOS mobile application built with NativeScript and Angular.

Authenticate With JWT In A NativeScript Angular Mobile Application

Any mobile application that accesses remote data will need authentication at some point in time.  There are many different authentication strategies out there, one of which is with Json Web Tokens (JWT) that we explored in one of my previous Node.js articles.  With JWT, users can authenticate via username and password, receive a signed token back, and use that token for any future API request rather than continuing to distribute the username and password.

In this tutorial we're going to explore how to build an Android and iOS mobile application using NativeScript and Angular that authenticates with an API and then uses a Json Web Token for future requests to that same API.

JavaScript Libraries In A TypeScript Application, Revisited

If you haven’t already gotten involved with it, you’ll probably know that TypeScript is becoming increasingly popular.  Being able to use a superset of JavaScript in a typed language that compiles down to JavaScript is a great thing.  However, if you’ve ever played around with TypeScript and tried to use JavaScript libraries, you’ll probably know that sometimes it can be a real pain.  Often JavaScript libraries do not ship with type definitions which are critical when it comes to playing nice with TypeScript.

If you’ve been keeping up with The Polyglot Developer you’ll probably remember two posts that were created.  Previously I had written about including external JavaScript libraries in an Angular application as well as adding type definitions to external JavaScript libraries in TypeScript.

We’re going to revisit these two articles and explore all the ways to include JavaScript libraries in TypeScript applications.  These include applications built with NativeScript, Ionic, and Angular.


Track The Device Geolocation In A NativeScript Angular Mobile Application

I get a particular set of questions quite a bit on my blog and other social media outlets.  One of these questions includes how to use geolocation features such as GPS tracking within a NativeScript mobile application for iOS and Android.  Many people want to be able to gather location information and in many cases use this information for mapping.

So what does it take to make use of the device GPS hardware for location tracking?

We’re going to see how to create a mobile application for Android and iOS using NativeScript and Angular that makes use of geolocation in a few different ways.