nativescript

How to routing in a app when I click a link from email

杀马特。学长 韩版系。学妹 提交于 2019-12-11 15:50:02
问题 I want to open my component in Application Android (Nativescript) from a link in email, that is Click here to reset password I have a link like this in email: http://secsystem.domain.tk/v1/resetPassword/11E8FC9 So when I click the link from my mobile browser I need the app Launched in component resetPassword. I use the following code: AndroidManifest.xml <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category

Access query parameters in iOS universal links in NativeScript

岁酱吖の 提交于 2019-12-11 15:39:34
问题 Question: how to access query parameters (e.g., ?id=bogus&time=now ) from a universal link on iOS in a NativeScript app using the urlhandler plugin? I'm developing a javascript NativeScript app that includes the nativescript-urlhandler plug-in. I need to be able receive a deep-link via sms, open the app, and access the full url of the link. This works fine on Android, but not on iOS. on iOS, the deep link opens the app, but does not trigger the handleOpenURL function. I've done several hours

Using twilio-chat with NativeScript and Angular

天大地大妈咪最大 提交于 2019-12-11 14:08:38
问题 I have the folowing chat service: import { Injectable, EventEmitter } from '@angular/core'; import { HttpClient } from '@angular/common/http'; import { Observable } from 'rxjs'; import * as Twilio from 'twilio-chat'; import Client from 'twilio-chat'; import { Channel } from 'twilio-chat/lib/channel'; @Injectable({ providedIn: 'root' }) export class ChatService { chatClient: Client; currentChannel: Channel; chatConnectedEmitter: EventEmitter<any> = new EventEmitter<any>();

Inject pure Java / Obj-C code in NativeScript App

北慕城南 提交于 2019-12-11 13:00:11
问题 I'm currently developing an App for Android / iOS, and now i'm at the stage to let my users interact with Facebook, and especially send private message to their friends. Facebook implement a SDK for that, for iOS: FBSDKSendButton *button = [[FBSDKSendButton alloc] init]; button.shareContent = content; [self.view addSubview:button]; And for android: SendButton sendButton = (SendButton)findViewById(R.id.fb_send_button); sendButton.setShareContent(shareContent); sendButton.registerCallback

Nativescript fs module not seeing folder or files

六眼飞鱼酱① 提交于 2019-12-11 12:54:24
问题 I'm using the Nativescript tutorial for creating a carousel here. The problem I'm running into is that I get the following error (minus my obfuscation) Error: Failed to load component from module: undefined.xml or file: /data/data/{Obfuscated}/files/app/pages/welcome/slides/slide1.xml when it tries to load xml files on this line (full snippet below): slides.push(builder.load(slidePath)) Upon some inspection I found that it's the file system that doesn't see the files I'm loading. My code is

Use YouTube Iframe API with Nativescript?

喜夏-厌秋 提交于 2019-12-11 12:50:37
问题 UPDATE: From @Manoj's code below and some other sources, I am now able to load the youtube player into a webview based on the Youtube iframe api. But the question still is: how can I have my app recognize when the video itself starts playing? (after the video loads, and after any ad plays). The key code is "trapped" in the webview. There is a nativescript-webview interface plugin that is meant to allow you to get information from the webview. If that is what is required here, what would be

Overlay positioning in NativeScript

不羁岁月 提交于 2019-12-11 11:10:50
问题 I'm working on a nativescript plugin for a material-inspired dropdown list of sorts. The plugin adds an AbsoluteLayout to the Page to act as a backdrop, then adds a ListView to that AbsoluteLayout so that the picker is displayed on top. It also adds a GridView with label and such that gets put in the position defined by its XML. Here's an example of the plugin in use in a view's XML: <GridLayout rows="auto" columns="*, auto"> <StackLayout> <label text="Color" /> <label style="height: 3;

Local Storage APIs do not work within NativeScript WebView

百般思念 提交于 2019-12-11 10:22:53
问题 My application is a web app hosted within a {N} WebView. The username & password are store in the localStore. When I leave the app and re-enter I do not have data and I have to go back to login. Could someone help me? or explain how to debug a web view in an app. the webpage is developed with Angular 4 and the app with NativeScript. 回答1: With Android localStorage APIs won't work until you enable them. You could enable it by accessing the native WebView's settings upon loaded event. export

How to use events in Nativescript ExoPlayer?

笑着哭i 提交于 2019-12-11 08:42:36
问题 Link to player: https://github.com/nstudio/nativescript-videoplayer I am using exoplayer in my nativescript project. I want to call a function when the player is ready to play the video. The documentation of this plugin is little bit unclear but player events are mentioned there: Event Description ------------------------------------------------- errorEvent This event fires when an error in the source code is thrown. playbackReadyEvent This event fires when the video is ready.

Detect App inactivity/idle timeout in NativeScript

孤者浪人 提交于 2019-12-11 08:39:41
问题 I need to detect user's inactivity time in NativeScript app. I tried with few plugins (like ng-idle) but they are not compatible with NativeScript. I also tried to to emit application level event (in page router outlet) but it is not working either. Any help will be appreciated. 回答1: In the mobile context, you would like to track the inactivity in the native mobile application lifecycle. For Android, you can extend the Application and implement some of the solutions shown here. Following this