O'Reilly logo

NativeScript for Angular Mobile Development by Nathanael J. Anderson, Nathan Walker

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Build recorder with AudioKit

We will begin by creating a model around our interaction with AudioKit's recording APIs. You could just start writing directly against these APIs right from your Angular component or service, but since we want to provide a consistent API across iOS and Android, there's a smarter way to architect this. Instead, we will abstract a simple API, usable across both platforms, which will tap into the correct native implementations under the hood. 

There will be a lot of interesting details related to AudioKit going on here, but create app/modules/recorder/models/record.model.ts with the following and we will explain some of the bits in a moment:

Later, we will add the .ios.ts suffix to this model, since it will contain ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required