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

What the correct way is to trigger the web intent in ios 12


Barcode reader crashes the app after permission request

$
0
0

@ioclaudio wrote:

Hi,
on an Ioni4 app, when I open the camera to read the QrCode the app crashes.
It crashes after the request of the permission of using the camera of the phone.
I’m using
phonegap-plugin-barcodescanner 8.0.1 "BarcodeScanner" and @ionic-native/barcode-scanner ^5.0.0 .

I’ve tried on Android6 and Android9 the result is the same.

Probably I didn’t install the right version of some component, but how can I know which of them is wrong?

This is the configuration of the system:

C:\Software\myapp>ionic info
Ionic:
   ionic (Ionic CLI)             : 4.12.0 
   Ionic Framework               : @ionic/angular 4.3.0
   @angular-devkit/build-angular : 0.13.8
   @angular-devkit/schematics    : 7.2.4
   @angular/cli                  : 7.3.8
   @ionic/angular-toolkit        : 1.4.1
Cordova:
   cordova (Cordova CLI) : 9.0.0 (cordova-lib@9.0.1)
   Cordova Platforms     : android 8.0.0, ios 5.0.1
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 3.1.2, (and 7 other plugins)
System:
   NodeJS : v10.15.3 (C:\Program Files\nodejs\node.exe)
   npm    : 6.9.0
   OS     : Windows 10
C:\Software\myapp>cordova plugin ls
cordova-plugin-add-swift-support 2.0.2 "AddSwiftSupport"
cordova-plugin-device 2.0.2 "Device"
cordova-plugin-geolocation 4.0.1 "Geolocation"
cordova-plugin-ionic-keyboard 2.1.3 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 3.1.2 "cordova-plugin-ionic-webview"
cordova-plugin-splashscreen 5.0.2 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
cordova-plugin-whitelist 1.3.3 "Whitelist"
phonegap-plugin-barcodescanner 8.0.1 "BarcodeScanner"
 @ionic-native/barcode-scanner        ^5.0.0  
 @ionic-native/core                   ^5.0.0  
 @ionic-native/geolocation            ^5.0.0  
 @ionic-native/splash-screen          ^5.0.0  
 @ionic-native/status-bar             ^5.0.0 

What could be the problem?
I have no error either running it in debug “ionic cordova run android”.

Posts: 1

Participants: 1

Read full topic

NSURLConnection error 1100 while running ionic app on iOS

$
0
0

@b5518388 wrote:

Same question like here: https://stackoverflow.com/questions/55967516/nsurlconnection-error-1100-while-running-ionic-app-on-ios

I have build an app with ionic 4 and cordova. On android the app runs like a charm but on iOS I just get some strange problems… like others do (https://stackoverflow.com/questions/48870411/ionic-ios-app-nsurlconnection-error-1100, https://stackoverflow.com/questions/55931112/ionic-4-app-shows-white-screen-on-ios-with-error-code-1100).
The app ionic build runs fine without any errors and just a few warnings of unused imports. Also the xcode build is fast and successfull. But when the app is running on a real device or simulator, I just get a blank white screen. In the console I get this with addional debugging:

I found like mentioned some similar issues and also added the environment variable (CFNETWORK_DIAGNOSTICS = 1) for advanced network logging to get more infos in the console (whole file: https://pastebin.com/Ew2rXPAd) or some snippets here:

2019-05-03 10:59:49.788736+0200 MyNiceApp[3426:1312031] CFNetwork Diagnostics [1:1] 10:59:49.787 {
DiskCookieStorage Construction: Binary{ Disk Cookies: { /private/var/mobile/Containers/Data/Application/23CCB045-0976-4DD0-A19B-0BD8CB6825FD/Library/Cookies/Cookies.binarycookies, <0 cookies in 0 domains> clean not writing } }
                     Accessing: <CFURL 0x282db3c60 [0x1bda5d610]>{string = file:///private/var/mobile/Containers/Data/Application/23CCB045-0976-4DD0-A19B-0BD8CB6825FD/Library/Cookies/Cookies.binarycookies, encoding = 13371337, base = (null)}
                          Path: /private/var/mobile/Containers/Data/Application/23CCB045-0976-4DD0-A19B-0BD8CB6825FD/Library/Cookies/Cookies.binarycookies
                Read from disk: <0 cookies in 0 domains>
                         Dirty: NO
                       Writing: NO
                        Policy: 0
} [1:1]
2019-05-03 10:59:49.788845+0200 MyNiceApp[3426:1312031] CFNetwork Diagnostics [1:2] 10:59:49.788 {
DiskCookieStorage Journaling On: Binary{ Disk Cookies: { /private/var/mobile/Containers/Data/Application/23CCB045-0976-4DD0-A19B-0BD8CB6825FD/Library/Cookies/Cookies.binarycookies, <0 cookies in 0 domains> clean not writing } }
                           File: <CFURL 0x282db3c60 [0x1bda5d610]>{string = file:///private/var/mobile/Containers/Data/Application/23CCB045-0976-4DD0-A19B-0BD8CB6825FD/Library/Cookies/Cookies.binarycookies, encoding = 13371337, base = (null)}
} [1:2]
2019-05-03 10:59:49.879254+0200 MyNiceApp[3426:1312031] Apache Cordova native platform version 5.0.0 is starting.
2019-05-03 10:59:49.879772+0200 MyNiceApp[3426:1312031] Multi-tasking -> Device: YES, App: YES
2019-05-03 10:59:49.901704+0200 MyNiceApp[3426:1312031] Using UIWebView
2019-05-03 10:59:49.904145+0200 MyNiceApp[3426:1312031] [CDVTimer][console] 0.041008ms
2019-05-03 10:59:49.904228+0200 MyNiceApp[3426:1312031] [CDVTimer][handleopenurl] 0.049949ms
2019-05-03 10:59:49.905236+0200 MyNiceApp[3426:1312031] Unlimited access to network resources
2019-05-03 10:59:49.905271+0200 MyNiceApp[3426:1312031] [CDVTimer][intentandnavigationfilter] 1.001954ms
2019-05-03 10:59:49.905338+0200 MyNiceApp[3426:1312031] [CDVTimer][gesturehandler] 0.050068ms
2019-05-03 10:59:49.905379+0200 MyNiceApp[3426:1312031] [CDVTimer][backgroundfetch] 0.025034ms
2019-05-03 10:59:49.905397+0200 MyNiceApp[3426:1312031] [CDVTimer][TotalPluginStartup] 1.327991ms
2019-05-03 10:59:50.139954+0200 MyNiceApp[3426:1312031] Resetting plugins due to page load.
2019-05-03 10:59:50.158278+0200 MyNiceApp[3426:1312115] CFNetwork Diagnostics [1:3] 10:59:50.158 {
LoaderWhatToDo: (null)
       Request: <CFURL 0x282db7c00 [0x1bda5d610]>{string = file:///var/containers/Bundle/Application/3D6B52AD-44AC-4749-9FF7-294382B47167/MyNiceApp.app/www/index.html, encoding = 13371337, base = (null)}
   CachePolicy: 0
      WhatToDo: originload
   CreateToNow: 0.00069s
} [1:3]
2019-05-03 10:59:50.161705+0200 MyNiceApp[3426:1312031] Failed to load webpage with error: The operation couldn’t be completed. (NSURLErrorDomain error -999.)
2019-05-03 10:59:50.162212+0200 MyNiceApp[3426:1312031] Resetting plugins due to page load.
2019-05-03 10:59:50.162894+0200 MyNiceApp[3426:1312115] CFNetwork Diagnostics [1:4] 10:59:50.162 {
LoaderWhatToDo: (null)
       Request: <CFURL 0x282d94060 [0x1bda5d610]>{string = file:///var/containers/Bundle/Application/3D6B52AD-44AC-4749-9FF7-294382B47167/MyNiceApp.app/www/index.html, encoding = 13371337, base = (null)}
   CachePolicy: 0
      WhatToDo: originload
   CreateToNow: 0.00030s
} [1:4]

And a bit later in the console log:

2019-05-03 10:59:50.278000+0200 MyNiceApp[3426:1312114] NSURLConnection finished with error - code -1100
2019-05-03 10:59:50.278024+0200 MyNiceApp[3426:1312114] NSURLConnection finished with error - code -1100

It seems like the app can’t load its own files… since the error -1100 means NSURLErrorFileDoesNotExist

Posts: 1

Participants: 1

Read full topic

Error npm serve (code ELIFECYCLE)

ionRefresher completed event?

$
0
0

@bilow wrote:

Hi,

I’d like to know if there is a way or workaround to track a ‘completed’ event for the ionRefresher within the html template only.

Obviously we call the refresherEvent.target.complete() in the ‘controller’ by hand so I can put the ‘extra’ lines there, but I want to handle some simple UI logic just in the html template itself.

What I had in mind:

<ion-refresher (ionRefresh)="refreshing = true; doRefreshStuff($event);" (ionCompleted)='refreshing = false;' slot="fixed" >
  <ion-refresher-content></ion-refresher-content>
</ion-refresher>

<ion-skeleton-text animated *ngIf='refreshing'></ion-skeleton-text>

So the idea is to control the 'refreshing' value only from within the template and (in this case) to show/hide the ion-skeleton-text component.

Looking forward to hear some ideas about this…
P.s. example is Ionic ‘4’ but this applies to all versions

Posts: 1

Participants: 1

Read full topic

Ionic 4 Skip Start-Page when user is logged in

$
0
0

@shorstmann wrote:

Hi all,

i have a app with a login-page.

If the user starts the app for the first time the login-page will be shown and the user has to login. If that was succesfull the app redirects the user to the menu-page (and this loads the tabs and so on).

Now, if the user closes the app or sends it to the background and reopens the app, the login-page is shown for a short period of time (less than 1 second) and it redirects again to the menu-page.

How can i prevent the login-page to be shown when the user is already logged in and the user is reopening the app? With ionic 3 that was no problem for me (using setRoot) but now with ionic 4 i face this problem (maybe because of the routes…?)

Here are some code snippets from my code:

app-routing.module.ts

const routes: Routes = [
  { path: '', redirectTo: 'login', pathMatch: 'full' },
  { path: 'login', loadChildren: './pages/login/loginPage.module#LoginPageModule' },
  { path: 'menu', canActivate: [AuthGuard], loadChildren: './pages/menu/menu.module#MenuPageModule' },
]

app.component.ts

 this.splashScreen.hide();
            this.authenticationService.authenticationState.subscribe(state => {
                if (state) {
                    this.navController.navigateRoot(['menu/tabs/dashboard']);
                } else {
                    this.navController.navigateRoot('login')
                }
            });

In my AuthGuard i simply check if the user is logged in and return true or false. I followed this tutorial: https://devdactic.com/ionic-4-login-angular/

What do i have to do?

Posts: 1

Participants: 1

Read full topic

ModalController > ModalModule loaded in page vs in app.module.ts

$
0
0

@mflmartin wrote:

Hi,

I am using ionic 4, and working with modals.

The problem I have is that my modals only work, in a given page, when I import them directly in the app.module.ts, but If load them in the page’s module (in order for the modals to be loaded when that module loads), then they don’t work.

This is my modal module:

@NgModule({
	declarations: [ScanListModal],
	imports: [
		CommonModule,
		FormsModule,
		IonicModule,
		BasePageModule
	],
	entryComponents: [ScanListModal]
})
export class ScanListModalModule {
}

And this is my page’s module, when loading the modal:


const routes: Routes = [
	{
		path: '',
		component: ScanSessionPage
	}
];

@NgModule({
	imports: [
		CommonModule,
		FormsModule,
		IonicModule,
		RouterModule.forChild(routes),
		BasePageModule,
		CommonComponentsModule,
                ScanListModalModule
	],
	declarations: [ScanSessionPage],
	providers: [],
	entryComponents: [],
	exports: []
})
export class ScanSessionPageModule {
}

And that does not work. But if I remove the import there, and import the modal’s module in app.module.ts, it works.

But my guts tells me that I should just load that modal in the modules that actually use them, not globally for the app, right?

Any help would be appreciated.

Thanks!

Ionic:

   ionic (Ionic CLI)             : 4.12.0 (C:\Users\marti\AppData\Roaming\npm\node_modules\ionic)
   Ionic Framework               : @ionic/angular 4.3.1
   @angular-devkit/build-angular : 0.13.8
   @angular-devkit/schematics    : 7.3.8
   @angular/cli                  : 7.3.8
   @ionic/angular-toolkit        : 1.5.1

Cordova:

   cordova (Cordova CLI) : 8.0.0
   Cordova Platforms     : none
   Cordova Plugins       : no whitelisted plugins (0 plugins total)

System:

   Android SDK Tools : 26.1.1 (C:\Users\marti\AppData\Local\Android\sdk)
   NodeJS            : v8.12.0 (C:\Program Files\nodejs\node.exe)
   npm               : 6.9.0
   OS                : Windows 10

Posts: 1

Participants: 1

Read full topic

How to exclude my ionic app from the android Battery Optimization

$
0
0

@claudioacanfora wrote:

Hi all, I’m a newbie here on the ionic/android developing world, so first, let me thanks anyone will answer me!

I’ve built a very simple Ionic 4 app that play some audio stream. It works nice, however the audio stops when the app goes in background, after more or less 3 minutes. This is due the Android Battery Optimization built in the system. (if you manually exlude the app from those optimizations, the app works forever…)

So my question: is there a way to exclude my app from those battery optimizations during the install process and/or at the first launch of my app?

I’ve been playing with the REQUEST_IGNORE_BATTERY_OPTIMIZATIONS attribute into the AndroidManifest.xml but so far, didn’t get it work.

Here the versioning of my environment:

Ionic:

   ionic (Ionic CLI)             : 4.12.0 
   Ionic Framework               : @ionic/angular 4.2.0
   @angular-devkit/build-angular : 0.13.8
   @angular-devkit/schematics    : 7.2.4
   @angular/cli                  : 7.3.8
   @ionic/angular-toolkit        : 1.4.1

Cordova:

   cordova (Cordova CLI) : 9.0.0 (cordova-lib@9.0.1)
   Cordova Platforms     : android 8.0.0
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 3.1.2, (and 8 other plugins)

System:

   Android SDK Tools : 26.1.1 
   NodeJS            : v8.9.3 
   npm               : 5.6.0
   OS                : Windows 10

Thanks again!

Posts: 2

Participants: 2

Read full topic


Ionic 4 Application is not working on Android 5.0 , android 5.1, android 6.0

$
0
0

@Thesurya9 wrote:

Ionic 4 application is not working on Android 5.0, Android 5.1, Android 6.0.

But ionic official claims it will support android 4.4 or greater.
But it’s not working. I m searching for a solution from last week.

I have decided to make an app in Ionic 4. I made very blunders mistake. Now I can not go back. it took me 2 months to develop the app from scratch, I very much disappointed.
Can someone please help me?

Posts: 1

Participants: 1

Read full topic

Ionic 4 icons not showing in android device

$
0
0

@KasunGamage wrote:

Ion icons seems to be not showing in android device.here is my packege.json

{
“name”: “test”,
“version”: “0.0.1”,
“author”: “Ionic Framework”,
“homepage”: “http://ionicframework.com/”,
“scripts”: {
“ng”: “ng”,
“start”: “ng serve”,
“build”: “ng build”,
“test”: “ng test”,
“lint”: “ng lint”,
“e2e”: “ng e2e”
},
“private”: true,
“dependencies”: {
@angular/common”: “^7.2.2”,
@angular/core”: “^7.2.2”,
@angular/forms”: “^7.2.2”,
@angular/http”: “^7.2.2”,
@angular/platform-browser”: “^7.2.2”,
@angular/platform-browser-dynamic”: “^7.2.2”,
@angular/router”: “^7.2.2”,
@ionic-native/camera”: “^5.3.0”,
@ionic-native/core”: “^5.0.0”,
@ionic-native/device”: “^5.5.0”,
@ionic-native/document-viewer”: “^5.4.0”,
@ionic-native/file”: “^5.0.0-beta.21”,
@ionic-native/file-opener”: “^5.0.0-beta.21”,
@ionic-native/file-transfer”: “^5.4.0”,
@ionic-native/in-app-browser”: “^5.2.0”,
@ionic-native/keyboard”: “^5.2.0”,
@ionic-native/ms-adal”: “^5.2.0”,
@ionic-native/network”: “^5.4.0”,
@ionic-native/splash-screen”: “^5.0.0”,
@ionic-native/status-bar”: “^5.0.0”,
@ionic-native/toast”: “^5.2.0”,
@ionic/angular”: “^4.3.1”,
@ionic/storage”: “^2.2.0”,
@okta/okta-angular”: “^1.2.0”,
@okta/okta-auth-js”: “^2.3.1”,
“angular-oauth2-oidc”: “^5.0.2”,
“cordova-android”: “7.1.4”,
“cordova-ios”: “4.5.5”,
“cordova-plugin-camera”: “4.0.3”,
“cordova-plugin-compat”: “^1.2.0”,
“cordova-plugin-device”: “^2.0.2”,
“cordova-plugin-document-viewer”: “^0.9.10”,
“cordova-plugin-file”: “^6.0.1”,
“cordova-plugin-file-opener2”: “^2.0.19”,
“cordova-plugin-file-transfer”: “^1.7.1”,
“cordova-plugin-inappbrowser”: “3.0.0”,
“cordova-plugin-ionic-keyboard”: “^2.1.3”,
“cordova-plugin-ionic-webview”: “^3.1.2”,
“cordova-plugin-ms-adal”: “^0.10.2”,
“cordova-plugin-network-information”: “^2.0.1”,
“cordova-plugin-splashscreen”: “^5.0.2”,
“cordova-plugin-statusbar”: “^2.4.2”,
“cordova-plugin-whitelist”: “^1.3.3”,
“cordova-plugin-x-toast”: “2.7.2”,
“cordova-sqlite-storage”: “3.1.0”,
“core-js”: “^2.5.4”,
“guid-typescript”: “^1.0.9”,
“ng2-pdf-viewer”: “^5.2.3”,
“ngx-logger”: “^3.3.12”,
“number-flip”: “^1.0.28”,
“rxjs”: “~6.3.3”,
“zone.js”: “~0.8.29”
},
“devDependencies”: {
@angular-devkit/architect”: “~0.12.3”,
@angular-devkit/build-angular”: “~0.13.0”,
@angular-devkit/core”: “~7.2.3”,
@angular-devkit/schematics”: “~7.2.3”,
@angular/cli”: “~7.3.1”,
@angular/compiler”: “~7.2.2”,
@angular/compiler-cli”: “~7.2.2”,
@angular/language-service”: “~7.2.2”,
@ionic/angular-toolkit”: “~1.4.0”,
@ionic/lab”: “1.0.24”,
@types/jasmine”: “~2.8.8”,
@types/jasminewd2”: “~2.0.3”,
@types/node”: “~10.14.2”,
“codelyzer”: “~4.5.0”,
“jasmine-core”: “~2.99.1”,
“jasmine-spec-reporter”: “~4.2.1”,
“karma”: “~3.1.4”,
“karma-chrome-launcher”: “~2.2.0”,
“karma-coverage-istanbul-reporter”: “~2.0.1”,
“karma-jasmine”: “~1.1.2”,
“karma-jasmine-html-reporter”: “^0.2.2”,
“protractor”: “~5.4.0”,
“ts-node”: “~8.0.0”,
“tslint”: “~5.12.0”,
“typescript”: “~3.1.6”
},
“description”: “An Ionic project”,
“cordova”: {
“plugins”: {
“cordova-plugin-whitelist”: {},
“cordova-plugin-statusbar”: {},
“cordova-plugin-device”: {},
“cordova-plugin-splashscreen”: {},
“cordova-plugin-ionic-webview”: {},
“cordova-plugin-ionic-keyboard”: {},
“cordova-plugin-ms-adal”: {},
“cordova-plugin-document-viewer”: {},
“cordova-plugin-file”: {},
“cordova-plugin-file-opener2”: {},
“cordova-plugin-inappbrowser”: {},
“cordova-sqlite-storage”: {},
“cordova-plugin-x-toast”: {},
“cordova-plugin-camera”: {},
“cordova-plugin-network-information”: {},
“cordova-plugin-file-transfer”: {}
},
“platforms”: [
“ios”,
“android”
]
}
}

Posts: 1

Participants: 1

Read full topic

Navigating from single page view to side-menu layout in ionic 4

$
0
0

@AndrewB wrote:

I’d like to build an app using Ionic 4 that simplistically works the following way:

  • On-boarding page is shown with some images/text
  • After user clicked ‘start’ button, some flag onboarded=true is written into local-storage
  • User redirected to the main app view which is a ion-split-pane containing side-menu layout
  • Next time when user launches app, I check if he/she already viewed on-boarding screen (by checking presence of onboarded var) and if it is - I immediately redirect the user to the main app having side-menu layout as I mentioned, omitting on-boarding screen

I started the project using ionic cli, based on side-menu template and modified it the following way to fulfill logic described above:

app.component.ts

import { Component } from '@angular/core';
import { Platform } from '@ionic/angular';
import { SplashScreen } from '@ionic-native/splash-screen/ngx';
import { StatusBar } from '@ionic-native/status-bar/ngx';
import { Storage } from '@ionic/storage';
import { Router } from '@angular/router';

@Component({
  selector: 'app-root',
  template: '<router-outlet></router-outlet>',
})
export class AppComponent {

  constructor(
    private platform: Platform,
    private splashScreen: SplashScreen,
    private statusBar: StatusBar,
    private storage: Storage,
    private router: Router
  ) {
    this.initializeApp();
  }

  async initializeApp() {

    await this.platform.ready();

    this.statusBar.styleDefault();

    this.splashScreen.hide();

    const onboarded = await this.storage.get('onboarded');

    if (onboarded) {

      this.router.navigate(['main-app']);

    } else {

      this.router.navigate(['onboarding']);
    }
  }
}

onboarding.page.html

<ion-header>
  <ion-toolbar>
    <ion-title>onboarding</ion-title>
  </ion-toolbar>
</ion-header>

<ion-content>
Welcome aboard!
<ion-button (click)="start()">Start app!</ion-button>
</ion-content>

onboarding.page.ts

import { Component } from '@angular/core';
import { Storage } from '@ionic/storage';
import { Router } from '@angular/router';

@Component({
  selector: 'app-onboarding',
  templateUrl: './onboarding.page.html',
  styleUrls: ['./onboarding.page.scss'],
})
export class OnboardingPage {

  constructor(
    private storage: Storage,
    private router: Router
  ) { }

  start() {

    this.storage.set('onboarded', true);

    this.router.navigate(['main-app']);
  }
}

main-app.page.html

<ion-app>
  <ion-split-pane>
    <ion-menu>
      <ion-header>
        <ion-toolbar>
          <ion-title>Menu</ion-title>
        </ion-toolbar>
      </ion-header>
      <ion-content>
        <ion-list>
          <ion-menu-toggle auto-hide="false" *ngFor="let p of appPages">
            <ion-item [routerDirection]="'root'" [routerLink]="[p.url]">
              <ion-icon slot="start" [name]="p.icon"></ion-icon>
              <ion-label>
                {{p.title}}
              </ion-label>
            </ion-item>
          </ion-menu-toggle>
        </ion-list>
      </ion-content>
    </ion-menu>
    <ion-router-outlet main></ion-router-outlet>
  </ion-split-pane>
</ion-app>

main-app.page.ts

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

@Component({
  selector: 'app-main-app',
  templateUrl: './main-app.page.html',
  styleUrls: ['./main-app.page.scss'],
})
export class MainAppPage {

  public appPages = [
    {
      title: 'Home',
      url: '/home',
      icon: 'home'
    },
    {
      title: 'List',
      url: '/list',
      icon: 'list'
    }
  ];

  constructor() { }

}

List and Home pages are just empty pages and their content is not important for this example
Problem is that main-app containing side menu and content is not working properly. I know that there is a problem in <ion-router-outlet main></ion-router-outlet>'s usage but couldn’t find the right solution.
Does anyone have ideas how to fix it?

Thanks!
Andrew.

Posts: 1

Participants: 1

Read full topic

How to PROPERLY check for latest app version

$
0
0

@SanduCuragau wrote:

From what I can imagine there’s 3 ways to know what is the latest versions:
1 - Check what is the latest version from a JSON file in the server
2 - Check what is the latest version from a table in the db
3 - Check what is the latest version from the app store itself

I know how to do 1 and 2 but I’ve searched on google and I don’t find how to do number 3 which would be the ideal one, do you guys know how do to it? If 3 ends up not working, which one do you guys recommend using, 1 or 2 ?

Also I have one more doubt:
In config.xml I can find version=“0.0.1” and that’s where I would expect to modify it too, but what’s up with this “version”: “0.0.1” in package.json ? do I have to change that one too or does changing one change the other?

Posts: 1

Participants: 1

Read full topic

Ionic cordova run android --device is not working on my new macbook

$
0
0

@pdj wrote:

with ionic cordova run android --device
it comes out error like below

cordova run android —device
ANDROID_HOME=/Users/pedrojung/Library/Android/sdk
JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_212.jdk/Contents/Home
/Applications/Android Studio.app/Contents/gradle/gradle-5.1.1/bin/gradle: Command failed with exit code EACCES

when I typed java -version.

and when I type cordova requirements

KakaoTalk_Photo_2019-05-04-01-45-52

i install android platform 6.3.0 and tried 6.4.0 neither works

Posts: 1

Participants: 1

Read full topic

APK not found after running ionic build --prod --release

$
0
0

@rohankapurmobile wrote:

I ran the following command:

ionic build --prod --release --platform=android

The build succeeded, however I am unable to locate the APK file generated. Any ideas as to where this might be?

Posts: 1

Participants: 1

Read full topic

Can I use this react native plugin in ionic 4


Multi touch

$
0
0

@shaileshrv1432 wrote:

Hi, I am working on some small application for learning purpose. I have some requirement where i have to use multi touch for the application. I have searched but i could not found anything here. Can anyone help me here. Thanks in advance.

Posts: 2

Participants: 2

Read full topic

[IONIC 4] Others methods to download files

$
0
0

@mathm3 wrote:

Hi!
I have problem with file transfer plugin, I can not download files (although in some tests I get a url through entry.toURL (), but on going the folder has nothing).

I wonder if have other ways to download files on Ionic 4 (Android and iOS) other than file-transfer?
I use Firebase Storage as a file / image server and I have the download url, also provided by Firebase Storage.

Thank you!

Posts: 1

Participants: 1

Read full topic

Scroll content to top/bottom using ionic 4 - Solution

$
0
0

@champion007 wrote:

Here is a working sample , tested on mobile devices and browsers for scrolling content top/bottom.

HTML Code -

<ion-header>
  <ion-toolbar>
    <ion-title>
      Scroll Content Example
    </ion-title>
  </ion-toolbar>
</ion-header>
<ion-content>
  <ion-button expand="block" (click)="scrollContent('bottom')">Scroll Bottom</ion-button>

  <ion-card class="welcome-card">
    <ion-img src="/assets/shapes.svg"></ion-img>
    <ion-card-header>
      <ion-card-subtitle>Get Started</ion-card-subtitle>
      <ion-card-title>Welcome to Ionic</ion-card-title>
    </ion-card-header>
    <ion-card-content>
      <p>Now that your app has been created, you'll want to start building out features and components. Check out some
        of the resources below for next steps.</p>
    </ion-card-content>
  </ion-card>

  <ion-card class="welcome-card">
    <ion-img src="/assets/shapes.svg"></ion-img>
    <ion-card-header>
      <ion-card-subtitle>Get Started</ion-card-subtitle>
      <ion-card-title>Welcome to Ionic</ion-card-title>
    </ion-card-header>
    <ion-card-content>
      <p>Now that your app has been created, you'll want to start building out features and components. Check out some
        of the resources below for next steps.</p>
    </ion-card-content>
  </ion-card>


  <ion-card class="welcome-card">
    <ion-img src="/assets/shapes.svg"></ion-img>
    <ion-card-header>
      <ion-card-subtitle>Get Started</ion-card-subtitle>
      <ion-card-title>Welcome to Ionic</ion-card-title>
    </ion-card-header>
    <ion-card-content>
      <p>Now that your app has been created, you'll want to start building out features and components. Check out some
        of the resources below for next steps.</p>
    </ion-card-content>
  </ion-card>


  <ion-card class="welcome-card">
    <ion-img src="/assets/shapes.svg"></ion-img>
    <ion-card-header>
      <ion-card-subtitle>Get Started</ion-card-subtitle>
      <ion-card-title>Welcome to Ionic</ion-card-title>
    </ion-card-header>
    <ion-card-content>
      <p>Now that your app has been created, you'll want to start building out features and components. Check out some
        of the resources below for next steps.</p>
    </ion-card-content>
  </ion-card>


  <ion-card class="welcome-card">
    <ion-img src="/assets/shapes.svg"></ion-img>
    <ion-card-header>
      <ion-card-subtitle>Get Started</ion-card-subtitle>
      <ion-card-title>Welcome to Ionic</ion-card-title>
    </ion-card-header>
    <ion-card-content>
      <p>Now that your app has been created, you'll want to start building out features and components. Check out some
        of the resources below for next steps.</p>
    </ion-card-content>
  </ion-card>

  <ion-button expand="block" (click)="scrollContent('top')">Scroll Top</ion-button>


</ion-content>

TS Code -

import { Component, ViewChild, ElementRef } from '@angular/core';
import { IonContent } from '@ionic/angular';
@Component({
  selector: 'app-tab1',
  templateUrl: 'tab1.page.html',
  styleUrls: ['tab1.page.scss']
})
export class Tab1Page {
  @ViewChild(IonContent) ionContent: IonContent;
  constructor() { }
  scrollContent(scroll) {
    if (scroll === 'top') {
      this.ionContent.scrollToTop(300); //300 for animate the scroll effect.
    } else {
      this.ionContent.scrollToBottom(300);  //300 for animate the scroll effect.
    }
  }
}

Posts: 1

Participants: 1

Read full topic

[Ionic 4] Open New Window in iOS Safari

$
0
0

@blakezeisler wrote:

I am trying to open a new window on a button click with the below code, but the button event is not triggered on iOS Safari. I can’t use inAppBrowser for this because it needs to work as a web app.

buttonClick() {
const newWindow = window.open(this.website.url, '_system');
newWindow.focus();
}

I appreciate any feedback

Posts: 1

Participants: 1

Read full topic

Create and update my device contact account

$
0
0

@atulmahankal wrote:

I want to use contact details to be sync in device account for contact and calender with my app name like Facebook, Google, WhatsApp, etc

I search & found many example to create contact, but it create contact in primary Google account.

I want to create my own app device account for contact and calender and sync it While use login into my app.

Posts: 1

Participants: 1

Read full topic

Viewing all 49308 articles
Browse latest View live


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