Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all 49083 articles
Browse latest View live

Android, can I pull address in parts?

$
0
0

@Wondernate wrote:

Hello,
I am not an ionic dev but I have worked with native and I am running into a problem on a project I have to manage. The developer is saying that on android, you can’t get the address from a phone contact in parts only as one string. Meaning, I can only fetch “123 main, city, ST, zip”, rather than say a json string that has “street”:“123main”, “City”:“city”… etc…

I have googled it and I can see plenty of examples of how to get an address but I am not finding one that shows the result I can expect.

Could someone tell me if that is true that ionic only lets me fetch an address string and not in parts? Even more amazing, maybe even tell me how the return looks or paste in an example?

Thank you for your time!

Posts: 1

Participants: 1

Read full topic


Transpile issue after upgrading to latest ionic

$
0
0

@rodneyjoyce wrote:

Hi, I upgraded to version 3.1.2 of Ionic App Scripts and version 3.9.2 of Ionic. When I do an “Ionic serve” it works fine. When I try to build in Prod mode it fails with “Failed to transpile TypeScript”:

I thought it might be something to do with the new "ngo" compiler option, however disablign it with the command below does not help.
This release adds support for ngo, the Angular team’s build optimizer tool. ngo is enabled by default on --prod builds. In the event that ngo is not working for your app or something goes wrong, it can be disabled by running the following build command: ionic cordova build ios --aot --minifyjs --minifycss --optimizejs

13:38:26]  typescript: C:/git/QueMesaMobile/src/core/utilities/push-notification.service.ts, line: 51
            Type '{ android: { senderID: string; }; ios: { alert: "true"; badge: "true"; sound: "true"; }; windows:...'
            is not assignable to type 'PushOptions'. Types of property 'android' are incompatible. Type '{ senderID:
            string; }' is not assignable to type 'AndroidPushOptions'. Object literal may only specify known properties,
            and 'senderID' does not exist in type 'AndroidPushOptions'.

      L50:  android: {
      L51:      senderID: this.environmentService.environment.androidPushNotificationSenderId
      L52:  },

Error: Failed to transpile TypeScript
    at errorCheckProgram (C:\git\QueMesaMobile\node_modules\@ionic\app-scripts\dist\aot\aot-compiler.js:119:39)
    at Object.<anonymous> (C:\git\QueMesaMobile\node_modules\@ionic\app-scripts\dist\aot\aot-compiler.js:89:21)
    at step (C:\git\QueMesaMobile\node_modules\@ionic\app-scripts\dist\aot\aot-compiler.js:32:23)
    at Object.next (C:\git\QueMesaMobile\node_modules\@ionic\app-scripts\dist\aot\aot-compiler.js:13:53)
    at fulfilled (C:\git\QueMesaMobile\node_modules\@ionic\app-scripts\dist\aot\aot-compiler.js:4:58)
[13:38:26]  copy finished in 17.27 s

cli packages: (C:\git\QueMesaMobile\node_modules)

@ionic/cli-utils  : 1.18.0
ionic (Ionic CLI) : 3.18.0

global packages:

cordova (Cordova CLI) : 7.1.0

local packages:

@ionic/app-scripts : 3.1.2
Cordova Platforms  : android 6.2.3 browser 4.1.0 ios 4.3.1
Ionic Framework    : ionic-angular 3.9.2

System:

Node : v6.10.0
npm  : 3.10.10
OS   : Windows 10

Environment Variables:

ANDROID_HOME : not set

Misc:

backend : legacy

Posts: 2

Participants: 2

Read full topic

Embed Youtube Video Wont Play (iOS)

$
0
0

@Fleisch wrote:

Im having a a weird issue with my embedded Youtube videos. I have included multiple iframes across ion-slides and in order to get them to play on iOS i have to tap on the “YouTube” watermark first then click the play button. Tapping on the play button first doesn’t do anything. Not having the same issue with ionic serve in browser.

Any ideas?

Posts: 1

Participants: 1

Read full topic

Ionic white screen of death on iOs

$
0
0

@timonggg wrote:

Hi there

My iOS App hangs after the splash screen. It just shows a white screen.

ionic info:

cli packages: (/usr/local/lib/node_modules)

    @ionic/cli-utils  : 1.18.0
    ionic (Ionic CLI) : 3.18.0

global packages:

    cordova (Cordova CLI) : not installed

local packages:

    @ionic/app-scripts : 3.1.2
    Cordova Platforms  : none
    Ionic Framework    : ionic-angular 3.7.1-201710060319

System:

    ios-deploy : 1.9.2
    Node       : v8.9.1
    npm        : 5.5.1
    OS         : macOS Sierra
    Xcode      : Xcode 9.1 Build version 9B55

Environment Variables:

    ANDROID_HOME : not set

Misc:

    backend : pro

package.json

{
  "name": "",
  "author": "",
  "homepage": "",
  "private": true,
  "scripts": {
    "clean": "ionic-app-scripts clean",
    "build": "ionic-app-scripts build",
    "lint": "ionic-app-scripts lint",
    "ionic:build": "ionic-app-scripts build",
    "ionic:serve": "ionic-app-scripts serve"
  },
  "dependencies": {
    "@angular/common": "4.2.5",
    "@angular/compiler": "4.2.5",
    "@angular/compiler-cli": "4.2.5",
    "@angular/core": "4.2.5",
    "@angular/forms": "4.2.5",
    "@angular/http": "4.2.5",
    "@angular/platform-browser": "4.2.5",
    "@angular/platform-browser-dynamic": "4.2.5",
    "@ionic-native/base64": "4.4.0",
    "@ionic-native/core": "4.4.0",
    "@ionic-native/date-picker": "4.4.0",
    "@ionic-native/fcm": "4.4.0",
    "@ionic-native/in-app-browser": "4.4.0",
    "@ionic-native/photo-viewer": "4.4.0",
    "@ionic-native/splash-screen": "4.4.0",
    "@ionic-native/status-bar": "4.4.0",
    "@ionic/cloud-angular": "0.12.0",
    "@ionic/storage": "1.1.6",
    "@types/crypto-js": "3.1.35",
    "angularfire2": "5.0.0-rc.3",
    "cordova-android": "6.2.3",
    "cordova-ios": "4.5.0",
    "cordova-plugin-add-swift-support": "1.6.1",
    "cordova-plugin-datepicker": "^0.9.3",
    "cordova-plugin-device": "1.1.4",
    "cordova-plugin-fcm": "^2.1.2",
    "cordova-plugin-inappbrowser": "^1.7.1",
    "cordova-plugin-ionic": "^2.0.3",
    "cordova-plugin-splashscreen": "~4.0.1",
    "cordova-plugin-statusbar": "2.2.1",
    "cordova-plugin-whitelist": "1.3.1",
    "crypto-js": "3.1.9-1",
    "firebase": "4.6.0",
    "ionic-angular": "3.7.1-201710060319",
    "ionic-img-viewer": "2.7.3",
    "ionic-plugin-keyboard": "~2.2.1",
    "ionicons": "3.0.0",
    "moment": "2.18.1",
    "rxjs": "5.5.2",
    "sw-toolbox": "3.6.0",
    "zone.js": "0.8.18"
  },
  "devDependencies": {
    "@ionic/app-scripts": "3.1.2",
    "typescript": "2.4.0"
  },
  "cordovaPlugins": [
    "cordova-plugin-whitelist",
    "cordova-plugin-console",
    "cordova-plugin-device",
    "cordova-plugin-statusbar",
    "cordova-plugin-splashscreen",
    "ionic-plugin-keyboard"
  ],
  "cordovaPlatforms": [
    "ios",
    {
      "platform": "ios",
      "version": "",
      "locator": "ios"
    }
  ],
  "description": "frontend: An Ionic project",
  "cordova": {
    "plugins": {
      "cordova-plugin-datepicker": {},
      "cordova-plugin-device": {},
      "cordova-plugin-splashscreen": {},
      "cordova-plugin-statusbar": {},
      "cordova-plugin-whitelist": {},
      "ionic-plugin-keyboard": {},
      "cordova-plugin-inappbrowser": {},
      "cordova-plugin-fcm": {}
    },
    "config": {
      "ionic_source_map": "source-map"
    },
    "platforms": [
      "android",
      "ios"
    ]
  }
}

In xcode it shows me the following messages:

<FIRInstanceID/WARNING> Failed to fetch APNS token Error Domain=com.firebase.iid Code=1001 “(null)”

Safari develop tool shows me the following:

It seems that it tries to access the plugin before it was created.

What I have done:

  • Added GoogleService-Info.plist to platforms/ios/project/Resources/Resources. Ionic Pro is currently not copying this file in a right way. So if you use Firebase with ionic you can’t use ionic pro for building.

  • Added APN key to firebase

  • Activated Push notifications and keychain sharing in xcode under capabilities

Any help would be appreciated.

Posts: 7

Participants: 2

Read full topic

(ionScroll) do not bind variables in its scope

$
0
0

@BrankoEnero wrote:

I need to update a variable by using (ionScroll) event in a component.

The example is simple. It has two files, a .ts file and a .html file that both are a component.

HTML file has:

  • The necessary text to scroll down and scroll up.
  • An (ionScroll) event in its “ion-content” that trigger an event each time that we scroll to any direction.

Typescript file has:

  • A variable that needs to be updated in its inverse boolean.
  • A method that set the inverse value of a variable.

ion-scroll-test.html

<ion-content (ionScroll)="updateVariable($event)">
  variableToUpdate: {{variableToUpdate}}<br>
/*
a lot of text to have some height to scroll down and up...
*/
</ion-content>

ion-scroll-test.component.ts

import {Component} from "@angular/core";

@Component({
  selector: 'ion-scroll-test',
  templateUrl: 'ion-scroll-test.html'
})

export class IonScrollTest {

  variableToUpdate: boolean = true;

  updateVariable() {
    this.variableToUpdate = !this.variableToUpdate;
    console.log('helo');
  }
}

So, the console.log in to updateVariable is shown in console, but the variable is not bound properly.

Can someone explain me why reason it has that behaviour?

And how can I resolve my problem?

Thanks.

Posts: 1

Participants: 1

Read full topic

App store reject app Guideline 4.2.2 - Design - Minimum Functionality

$
0
0

@umefarooq wrote:

Hi i have submitted my app 3 times for app store reviews all 3 times they have rejected it, i don’t have any idea how to pass through this guide line. this app store review process really drive me crazy, this my first app for app store here are some screen shots of my app

my app is published on google play store up and running. app store :rage::rage::rage:

here is guide lines link
https://developer.apple.com/app-store/review/guidelines/#minimum-functionality

any solution or idea more than welcome.

Posts: 2

Participants: 2

Read full topic

Change Webview

$
0
0

@Cmmchado2017 wrote:

Hi guys, I need a help, I need to change the webview (android) to the old implementation.
My app needs to write txt file. and need to mantain the old webview. I tried to change but I don´t have any success to change,
Somebody can help to change the plugin?

Posts: 3

Participants: 2

Read full topic

Upload image to POST rest api

$
0
0

@jicee13 wrote:

I would like to upload an image via a POST request to my rest API. Can someone point me in the right direction of how to do this with ionic and what to pass in my post request?

Posts: 1

Participants: 1

Read full topic


Problems to generate apk

$
0
0

@Cj10 wrote:

Good evening
I already updated the version of android, ionic, cordova and nodejs
When performing the command ionic cordova platform add android works correctly.
however when performing the command ionic cordova build android the following error occurs:
Warning: License for package with an exception
A problem occurred configuring root project android
You have not accepted the license agreements of the following SDK components: Android SDK Platform 26
Error: Command failed with an exception
Alternatively to learn how to transfer the license agreements from one workstation to another, go to http://d.android.com/r/studio-ui/export-licenses.html
Can anyone get a solution?
Thanks

Posts: 1

Participants: 1

Read full topic

A popular app built on Ionic

Ionic cordova emulate bug

$
0
0

@godefroid wrote:

> cordova requirements

Requirements check results for android:

Java JDK: installed 1.8.0

Android SDK: installed true
Android target: installed android-26,android-25,android-24,android-23
Gradle: installed /Applications/Android Studio.app/Contents/gradle/gradle-4.1/bin/gradle

Requirements check results for ios:

Apple macOS: installed darwin
Xcode: installed [object Object]
ios-deploy: installed [object Object]

CocoaPods: not installed
/bin/sh: /usr/local/bin/pod: /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby: bad interpreter: No such file or directory

Error: Some of requirements check failed
> cordova run android --list --emulator
Available android virtual devices:

Nexus_5_API_26
Nexus_6_API_23
ionic cordova emulate android --verbose
[DEBUG] Reason for not using local CLI: LOCAL_CLI_NOT_FOUND
[DEBUG] CLI flags: { interactive: true, confirm: false }
[DEBUG] { cwd: '/Users/gillesgodefroid/Documents/Test', local: false, binPath:
        '/usr/local/lib/node_modules/ionic/bin/ionic', libPath:
        '/usr/local/lib/node_modules/ionic/dist/index.js' }
[DEBUG] Daemon found (pid: 2011)
> cordova platform add i --save
Using cordova-fetch for i

Adding i project...

Unable to load PlatformApi from platform. Error: Unhandled "error" event. (Does not appear to implement platform Api.)

Error: Unhandled "error" event. (The platform "i" does not appear to be a valid cordova platform. It is missing API.js. i not supported.)

[ERROR] Exception:

Posts: 3

Participants: 2

Read full topic

Built ionic app doesn't send requests

$
0
0

@ArniDzhan wrote:

Good day.
My application has stopped sending requests and it seems like angular-routing doesn’t work too.
When I use ionic serve everything is fine. My app works correctly.
After running command ionic cordova build browser --no-interactive --prod app successfully built, but works incorrect.
All files in their places, routing set correctl. Seems like the thing in a build.
Any ideas?

ionic info

cli packages: (C:\Users\Nebesky\AppData\Roaming\npm\node_modules)

@ionic/cli-utils  : 1.13.1
ionic (Ionic CLI) : 3.13.2

global packages:

cordova (Cordova CLI) : 7.1.0

local packages:

@ionic/app-scripts : 1.3.8
Cordova Platforms  : none
Ionic Framework    : ionic-angular 2.0.0-rc.5

System:

Android SDK Tools : 26.0.2
Node              : v6.11.1
npm               : 5.3.0
OS                : Windows 10

Misc:

backend : legacy

Posts: 1

Participants: 1

Read full topic

Space between columns

$
0
0

@cpigusch wrote:

I would like the text in my column to sit nearly right next to each other but right now there is a HUGE gap between them. How do I stop that from happening?

Feels Like: {{weather.feelslike_f}} Humidity: {{weather.relative_humidity}} Visibility: {{weather.visibility_mi}} Dewpoint: {{weather.dewpoint_f}} Pressure: {{weather.pressure_in}} UV Index: {{weather.UV}}

Posts: 1

Participants: 1

Read full topic

Ionic 2 first item on list hidden by header on return to page

$
0
0

@lemurmonky wrote:

I had some weird behavior with the following ( very basic code ) , the top item in the list would be displayed on an android device on first navigation, however, after navigating away and back to the page, the first item on the list would appear hidden.

<ion-header>
  <ion-navbar>
    <ion-title>task</ion-title>
  </ion-navbar>
</ion-header>


<ion-content>
  <ion-list>
        <button ion-item *ngFor="let item of taskList" (click)="itemSelected(item)">
          {{ item }}
        </button>
      </ion-list>
</ion-content>

i tried

  1. adding a margin
  2. using has-header - css attribute ( which is apparently not required for ionic2 )
  3. using content.scrollToTop()

none of which worked.

through trial and error got to this to work

import { Component,ViewChild } from '@angular/core';
......

  @ViewChild(Content) content: Content;

ionViewDidEnter()
  {
    console.log('ionViewDidEnter FacilityTaskPage');
    this.content.resize();
  }

I still don’t understand why this works, but have posted in case

  1. somebody knows why
  2. somebody has a similar problem

Posts: 1

Participants: 1

Read full topic

Support old versions android without using crasswalk

$
0
0

@arsene123 wrote:

hello, we launch our application in two weeks and we want to support also the old android version without using crasswalk. Thanks

Posts: 3

Participants: 2

Read full topic


App not making http call

$
0
0

@ebozzetti_thorlabs wrote:

I’m having some issue after I build my app for iOS with http calls. When I use ionic serve and test my app on the browser all the http calls work fine, but after I build it for iOS when I try my app on my iPhone it does not make any http class.

I do have the the following on my config

Do I need to add anything else? I’m using @angular/http should I use this (http://ionicframework.com/docs/native/http/) instead?

Posts: 1

Participants: 1

Read full topic

How to make notification when expired product

$
0
0

@Natadsada93 wrote:

How can I make notification when expired product ?. I had try with Firebase Cloud Messaging but it doesn’t meet my requirements. Would you recommend what I could do?. Thank You :slight_smile:

Posts: 1

Participants: 1

Read full topic

How to publish device id based app in iOS App store

$
0
0

@Phanitechie wrote:

I have an ionic app where im using device id based login here the scenario is after the opening the app the customer will see the device id displayed on the screen and he will inform the id to the support people and then the app gets validated and then by pressing login button the user can login here the problem is I want to submit this app to the app store but for beta review how can I give sign-in access to apple people?

Posts: 1

Participants: 1

Read full topic

How to add angular material theme?

$
0
0

@HarinderSingh wrote:

How and where to add angular material theme?
// Import a pre-built theme
@import ‘~@angular/material/prebuilt-themes/deeppurple-amber.css’;

Posts: 1

Participants: 1

Read full topic

How to change 4 text color in on click function,

$
0
0

@Madhawa wrote:

Im using ionic 3 ,
I’m added the

Text one

Text two

Text three

When I Click on the text I need to change the color on text , I can do it normal java script but Im try to do it for a Ionic3, i cant do that, please help me to fix it How to change 4 text color in on click function,

Thanks

Posts: 1

Participants: 1

Read full topic

Viewing all 49083 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>