New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: refresher stop working if not in a delayed call #20803
Comments
Thanks for the issue. Can you provide a repo with the code required to reproduce this issue? |
Is there an online ionic5 that I can use like the https://stackblitz.com/edit/ionic-v4-angular-tabs ? |
@RoyeA You can just install Ionic Framework v5 in that starter. |
Hi @liamdebeasi, I tried to modify the code for v5, but I guess I truly don't know how to install ionic framework v5 in that starter :( |
It might be easier to create your project in a GitHub repo and send a link. |
Here is the link to the repo |
Thanks for the issue. Can you try the following dev build and let me know if it resolves the issue?
|
Same behavior :( |
What device are you testing this on? |
On a Ubuntu linux desktop, using "ionic serve". |
Ok try this dev build:
|
We have a winner. |
Thanks for the issue. This has been resolved via #20815 and will be available in an upcoming release of Ionic Framework. |
Thank you |
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out. |
Bug Report
Ionic version:
[x] 5.x
Current behavior:
When using an ion-refresher that needs to be canceled/complete in a non-delayed code, the ion-refresher will stop to respond for secondary pull/use.
Expected behavior:
when calling on the event.target.complete() ( regardless if in delayed code, or direct ) the refresher needs to be ready for any future use/pull.
Steps to reproduce:
in the html:
.
.
.
<ion-refresher slot="fixed" (ionRefresh)="doRefresh($event)">
.
.
.
In the *.ts code:
doRefresh(event){
event.target.complete();
}
Other information:
The only solution that I found is to wrap the complete() in a setTimeout call as follows:
setTimeout(()=>{event.target.complete();},0);
Ionic info:
Ionic:
Ionic CLI : 6.2.0 (/usr/local/lib/node_modules/@ionic/cli)
Ionic Framework : @ionic/angular 5.0.5
@angular-devkit/build-angular : 0.803.25
@angular-devkit/schematics : 8.3.25
@angular/cli : 8.3.25
@ionic/angular-toolkit : 2.2.0
Utility:
cordova-res : not installed
native-run : 0.3.0
System:
NodeJS : v12.14.1 (/usr/local/node-v12.14.1-linux-x64/bin/node)
npm : 6.13.4
OS : Linux 4.15
The text was updated successfully, but these errors were encountered: