Book Image

NativeScript for Angular Mobile Development

By : Nathan Walker, Nathanael J. Anderson
Book Image

NativeScript for Angular Mobile Development

By: Nathan Walker, Nathanael J. Anderson

Overview of this book

NativeScript is an open source framework that is built by Progress in order to build truly native mobile apps with TypeScript, JavaScript or just Angular which is an open source framework built by Google that offers declarative templates, dependency injection, and fully featured modules to build rich applications. Angular’s versatile view handling architecture allows your views to be rendered as highly performant UI components native to iOS and Android mobile platforms. This decoupling of the view rendering layer in Angular combined with the power of native APIs with NativeScript have together created the powerful and exciting technology stack of NativeScript for Angular. This book focuses on the key concepts that you will need to know to build a NativeScript for Angular mobile app for iOS and Android. We’ll build a fun multitrack recording studio app, touching on powerful key concepts from both technologies that you may need to know when you start building an app of your own. The structure of the book takes the reader from a void to a deployed app on both the App Store and Google Play, serving as a reference guide and valuable tips/tricks handbook. By the end of this book, you’ll know majority of key concepts needed to build a successful NativeScript for Angular app.
Table of Contents (24 chapters)
Title Page
About the Authors
About the Reviewer
Customer Feedback
Integration Testing with Appium

Phase 2 – Building an audio recorder for Android

Believe it or not we've actually done most of the heavy lifting to make this work on Android already! That's the beauty of NativeScript. Designing an API that makes sense, as well as an architecture that can plug/play underlying native APIs, is key to NativeScript development. At this point, we just need to plug in the Android pieces into the shape we have designed. So, to summarize, we now have the following:

  • RecorderService that works in tandem with PlayerService to coordinate our multitrack handling abilities
  • A Waveform view that is flexible and ready to provide an Android implementation under the hood
  • RecordModel that should tap into the appropriate underlying target platform APIs and be ready for Android details to be plugged into
  • Built interfaces defining the shape of the model, for Android models to simply implement to know which API they should define

Let's get to work.

We want to rename record.model.ts to record.model.ios.ts, since it's...