Quantcast
Channel: Ionic Forum - Latest posts
Viewing all 230429 articles
Browse latest View live

Ionic selected value after fill select not reflected in UI

$
0
0

Hi,

I have a form with a select component that I fill with for cicle.
After I fill the select in ts file, I make

this.skillForm.controls[“skill_level_id”].setValue(skill_level_id);

But I see nothing in the UI, the text of selected element is not showing…but if I open the select I see that the value is selected in right way.
This is a piece of my code on pastebin

https://pastebin.com/X0UaAXwk


how to use primeNG with ionic 3?

$
0
0

Hey Anna_Liebt, thanks!
I followed the documentation to use the primeNG, after doing the ionic integration step by step with primeng, the component appears, but the component style of primeNG does not appear.
Here’s how the component:

this error appears in the console:
Refused to apply style from ‘http://localhost:8100/node_modules/primeng/resources/themes/omega/theme.css’ because its MIME type (‘text/html’) is not a supported stylesheet MIME type, and strict MIME checking is enabled.

Ionic cordova run with –prod stuck at splash for iOS and Android

$
0
0

how can I do that?
now when I run ionic start tab,
it create ionic 4 I think. becouse I have updated my ionic -g

Smart glass

$
0
0

Probably no, but it depends how you build aps for theses glasses in general.

Ionic uses Cordova (or Capacitor) in the background to wrap the Ionic web app into a native app that can be installed on Android, iOS etc. If Cordova supports your target platform, then Ionic does as well. But Cordova only supports a limited number of platforms: https://github.com/apache/cordova#platforms

If those glasses run on Android, which is supported by Cordova, then it further depends on wether the apps running there can embed a WebView to display a web app. Onyl then can a Ionic app work.

E2E testing when using @ionic/storage

$
0
0

What exactly is your question? You normally just use the APIs that @ionic/storage gives you, how and where your data is saved doesn’t really concern you.

How Reinstall Ionic Version 3 with Correctly

$
0
0

What is “Correctly”?

In general it doesn’t matter which Ionic CLI version oyu install - they work with all Ionic Framework versions from 1.x up to the newest 4.x.

To start a new Ionic v3 app with the CLI, use ionic start --type=ionic-angular. This should probably create a 3.9.2 app.

Ionic cordova run with –prod stuck at splash for iOS and Android

How do I promote sports betting game website in USA?

$
0
0

if you are looking to promote sport betting App in USA, consider running a facebook ads to reach your target audience. facebook have a billion visit every single day so to my own experience, all your audience are already on facebook. you only need how to run facebook ads perfectly to reach those audience

you can start running ads with nothing less than $5 dollar per day ads


Ion-select-option is not binding imgs

$
0
0

How to bind dyanamic Img in ion select option

Deeplinks not assignable to provider

Ionic cordova run with –prod stuck at splash for iOS and Android

$
0
0

Im trying to create new project and transfer component/pages/models one by one and share the result again.

Fragment Shader Error

$
0
0

Hello Guys!! I’m using tensorflow js in my project and when a execute the function estimateSinglePose the result is an error. Does someone use TensorFlor JS MobileNet?
my code:

import * as posenet from '@tensorflow-models/posenet';

const imageScaleFactor = 0.5;
const outputStride = 16;
const flipHorizontal = true;

convertToDataURLviaCanvas(url, outputFormat){
    return new Promise((resolve, reject) => {
    let img = new Image();
    img.crossOrigin = 'Anonymous';
    img.onload = () => {
        let canvas = <HTMLCanvasElement> document.createElement('CANVAS'),
          ctx = canvas.getContext('2d'),
          dataURL;
        canvas.height = img.height;
        console.log(canvas.height);
        canvas.width = img.width;
        console.log(canvas.width);
        ctx.drawImage(img, 0, 0);
        dataURL = canvas.toDataURL(outputFormat);


        resolve(dataURL);
        canvas = null;
      };
      img.src = url;
      this.estimatePoseOnImage(img);
    });
  }

  async estimatePoseOnImage(imageElement){
    let poses = [];
    const net = await posenet.load();

    const pose = await net.estimateSinglePose(imageElement, imageScaleFactor, flipHorizontal, outputStride);
    poses.push(pose);
    console.log(poses);
}

Ionic:

ionic (Ionic CLI) : 4.9.0 (C:\Users\renan\AppData\Roaming\npm\node_modules\ionic)
Ionic Framework : ionic-angular 3.9.2
@ionic/app-scripts : 3.2.1

Cordova:

cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1)
Cordova Platforms : android 7.1.1
Cordova Plugins : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 2.3.1, (and 5 other plugins)

System:

Android SDK Tools : 26.1.1 (C:\Users\renan\AppData\Local\Android\Sdk)
NodeJS : v10.15.0 (C:\Program Files\nodejs\node.exe)
npm : 6.4.1
OS : Windows 10

Ionic json data and infinite scroll

$
0
0

Hello all,

I have a question. When Im pulling data from an external json file nothing is wrong but when I use the infinite scroll for the same data then suddenly all data is invisible. What tutorial of infionite scroll I use nothing works.

Is there something wrong with infinite scroll and json data? Or is there a sort same manner to to this also?

Ionic Studio?

$
0
0

Hi,

today I stumbled upon Ionic Studio, followed the lnik, was fascinating when I read

Ionic Studio is a powerful, locally-installed, visual development environment that makes it easy to build stunning apps in minutes.

read the pricing, the Starter plan is great for me, followed the link expecting to find a download…
is there a download? “Locally-installed” sounds like should be one?

E2E testing when using @ionic/storage

$
0
0

My question is how i can use @ionic/storage in E2E tests. In my page, i do like this:

import { Storage } from '@ionic/storage';
..
constructor(
      private storage: Storage      
  ) { .. }

Then in this page i can use storage like this:

this.storage.set("somevalue", "the actiual value");

and

this.storage.get("somevalue")

I’ve tried to import and use @ionic/storage in the E2E test script, but i don’t see how i can use it there.
Tried it this way:

import {Storage} from '@ionic/storage';
describe('Dashboard E2E test', () => {
    beforeEach(() => {
       let storageConfig = { name: 'somename' };
        let storage: Storage = new Storage(storageConfig);
        this.storage.get("somevalue").subscribe(res => {
           ..          
        })
 

when trying to run tests, i get this:

[13:29:41] I/launcher - Running 1 instances of WebDriver
[13:29:41] I/direct - Using ChromeDriver directly...
[13:29:42] E/launcher - Error: /Users/xxxx/dev/nnnn/node_modules/@ionic/storage/dist/index.js:1
(function (exports, require, module, __filename, __dirname) { import { NgModule } from '@angular/core';
                                                              ^^^^^^

SyntaxError: Unexpected token import
    at createScript (vm.js:80:10)
    at Object.runInThisContext (vm.js:139:10)
    at Module._compile (module.js:616:28)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Module.require (module.js:596:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/Users/xxxx/dev/nnnn/src/pages/dashboard/dashboard.e2e-spec.ts:5:17)
[13:29:42] E/launcher - Process exited with error code 100
npm ERR! code ELIFECYCLE
npm ERR! errno 4
npm ERR! nnnn@0.0.2 e2e-test: `protractor ./test-config/protractor.conf.js`
npm ERR! Exit status 4
npm ERR! 
npm ERR! Failed at the nnnn@0.0.2 e2e-test script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/xxxx/.npm/_logs/2019-01-31T12_29_42_759Z-debug.log

I’m not sure if this clarifies what my question is. and maybe it’s even a stupid question. I just don’t see how i am supposed to do this. So I could use a pointer in the right direction.


E2E testing when using @ionic/storage

$
0
0

So you are testing your app in Chrome, and want to look into the app’s storage to confirm everything worked as expected? Wouldn’t it be more “e2e” to check if the app correctly displays the data (which it loads from storage)?

Ionic Studio?

Ionic cordova run with –prod stuck at splash for iOS and Android

$
0
0

Make sure to test regularly, so you know exactly when it breaks.

Cordova platform browser and PWA

$
0
0

Ionic Native would be for Cordova’s browser platform, but not that many plugins really support it.
Using HTML5 would be an alternative solution.
There is also Ionic Capacitor, a replacement for Cordova, which has better/different support for web as a build target via PWAs. Worth looking into.

E2E testing when using @ionic/storage

$
0
0

My app uses authentication with Auth0, I want to test what’s going on inside the app, so my thought is to act like the user has already logged in once, and has a token saved in local storage. The validity of the token is checked before the user is allowed into the dashboard.

So what I’m trying to do, is to make use of the saved token, to actually be able to get to the dashboard page. If that makes sense.

Viewing all 230429 articles
Browse latest View live


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