Questions tagged [angular2-nativescript]

NativeScript + Angular is an open source framework created by Telerik that makes native mobile app development easier for developers with web-dev background. It enables developers to use Angular to build native mobile applications for iOS and Android.

1264 questions
8
votes
2 answers

NativeScript Installation Issues

I was just trying to install NavtiveScript, for this I followed the official installation guide available at http://docs.nativescript.org/angular/start/quick-setup but I am stuck at "Step 3: Install iOS and Android requirements" When I run the…
Naveed Ahmed
  • 10,048
  • 12
  • 46
  • 85
7
votes
1 answer

Nativescript - Set the target IOS version for Nativescript plugins

I recently updated my xcode to the beta for Xcode12 so I can see how my app will run on the upcoming release of IOS 14 When trying to run TNS RUN IOS I get the following errors: Saving metadata generation's stderr stream to:…
7
votes
1 answer

brew cask install android-sdk

I’m having problem to install android sdk (brew cask install android-idk) on Mac OS X. I tried to install it for nativescript. I read on people that had the same problem but i couldn't find working solution. I tried to change the java path maybe it…
haim
  • 589
  • 3
  • 7
  • 11
7
votes
2 answers

Class 'Subject' incorrectly extends base class 'Observable Nativescript navigation drawer error

# This is the error I am facing now: i downloaded navigation drawer sample using npm (https://github.com/shripalsoni04/nativescript-angular-drawer-template). but it gives the following error. dhrn@dhrn-Inspiron-5548:~/NativeApp/Supervisor$ tns run…
7
votes
3 answers

how to give border and border-radius to stacklayout in nativescript

I'm new to nativescript.I don't know how to give border and border-radius to stacklayout. Below I have posted what I tried so far: component.html:
7
votes
4 answers

NativeScript handling back button event

I am trying to handle the hardware back button in a NativeScript app. I am using NativeScript version 2.3.0 with Angular. Here is what I have in main.ts file // this import should be first in order to load some required settings (like globals and…
krv
  • 2,830
  • 7
  • 40
  • 79
6
votes
1 answer

nativescript-toast not showing on iOS

After I updated to the latest version of nativescript-toast it stopped working in iOS (In Android it's working fine). I mean, the toast are not being shown, while the app works as expected. In the previous version everything was as expected. But…
Faabass
  • 1,394
  • 8
  • 29
  • 58
6
votes
2 answers

Is it possible to create Custom Push Notifications with a REST service backed server?

I have an OpenEdge database, I have created a REST Service and am able to CRUD to it from the outside World. I have created a Nativescript app that can pull data from the REST service etc, but now i want Push notifications. I know about the…
6
votes
2 answers

What is the best ways to set up different environment variables for NativeScript with Angular?

In Angular, the the de facto way to load env vars into the app is using environment.ts which is part of the cli. In NativeScript, it seems like that doesn't work with the NativeScript cli. What's the best way to do so?
Ka Mok
  • 1,937
  • 3
  • 22
  • 47
6
votes
3 answers

cannot read property global array of undefined in nativescript angular2

I got a runtime error as cannot read property listArr of undefined. I need to reuse that same array in multiple components. That's why I'm using Global array I have added relevant code.please check it. Global.ts : export class Global { public…
Stephen
  • 9,899
  • 16
  • 90
  • 137
6
votes
0 answers

ngTemplateOutlet: Cannot assign to a reference or variable

When using ngTemplateOutlet and context: The context data: this.Context = { $implicit: this.userName, 'password': this.password, 'Login':…
6
votes
2 answers

NativeScript: max number of lines on a Label

If I add textWrap="true" to a Label, text is wrapped over several lines, so far so good. But I have a very long string and our design only have room for two lines. How do I limit the Label to max two lines? I'd prefer not to set a height, since that…
mabs
  • 987
  • 1
  • 10
  • 17
5
votes
2 answers

Using Angular libraries in Nativescript code sharing project

I'm trying to migrate an Angular app to a shared codebase with Nativescript using the new @nativescript/schematics, however, I'm having problems importing my Angular library when building the mobile version of the app. I used the angular-cli to…
5
votes
2 answers

how to add horizontal line in nativescript-angular html file

I tried "hr" tag in component html file in nativescript-angular. But it doesn't shown horizontal line in simulator. (tested with ios simulator) hr>
1
2
3
84 85