You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When inside the app-busy-day component change detection does not seem to work.
template has {{counter}}
component has this.counter = this.counter + 1;
Counter in template does not increment, only after using changeDectectorRef
Expected Behavior
Change detection should work as normal.
Steps to Reproduce
spawn an inline modal with a component, bind an object to it [passableObject] = data
component uses this as @input passableObject,
define a counter on the component, and try to use a button to increment the counter.
display counter in template as
Thanks for the issue! This issue has been labeled as needs reproduction. This label is added to issues that need a code reproduction.
Please reproduce this issue in an Ionic starter application and provide a way for us to access it (GitHub repo, StackBlitz, etc). Without a reliable code reproduction, it is unlikely we will be able to resolve the issue, leading to it being closed.
If you have already provided a code snippet and are seeing this message, it is likely that the code snippet was not enough for our team to reproduce the issue.
For a guide on how to create a good reproduction, see our Contributing Guide.
Can be closed, we couldn't find the issue cause we didnt understand the origin of it. Updating to 6.0.3. fixes the issue,
I assume its
angular: attach change detector ref for inline overlays (#24521) (5c54593), closes #24502
This fix in particular that makes it work. We close the issue.
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.
Prerequisites
Ionic Framework Version
Current Behavior
We have a list of action components, those components when clicked spawn an ion-modal.
<ion-modal trigger="modal-{{ a.busyDayId }}" [showBackdrop]="true">
<app-busy-day [a]="a">
When inside the app-busy-day component change detection does not seem to work.
template has {{counter}}
component has this.counter = this.counter + 1;
Counter in template does not increment, only after using changeDectectorRef
Expected Behavior
Change detection should work as normal.
Steps to Reproduce
spawn an inline modal with a component, bind an object to it [passableObject] = data
component uses this as @input passableObject,
define a counter on the component, and try to use a button to increment the counter.
display counter in template as
Code Reproduction URL
No response
Ionic Info
$ ionic info
[WARN] Error loading @capacitor/ios package.json: Error: Cannot find module '@capacitor/ios/package'
[WARN] Error loading @capacitor/android package.json: Error: Cannot find module '@capacitor/android/package'
Ionic:
Ionic CLI : 6.18.1 (C:\Users-\AppData\Roaming\npm\node_modules@ionic\cli)
Ionic Framework : @ionic/angular 6.0.3
@angular-devkit/build-angular : 13.0.4
@angular-devkit/schematics : 13.0.4
@angular/cli : 13.0.4
@ionic/angular-toolkit : 5.0.3
Capacitor:
Capacitor CLI : 3.3.3
@capacitor/android : not installed
@capacitor/core : 3.3.3
@capacitor/ios : not installed
Utility:
cordova-res : not installed globally
native-run : 1.5.0
System:
NodeJS : v16.13.2 (C:\Program Files\nodejs\node.exe)
npm : 8.1.2
OS : Windows 10
Additional Information
Using changetracking like,
private ref: ChangeDetectorRef
this.a.counter++;
this.ref.detectChanges();
Does update counter properly.
The text was updated successfully, but these errors were encountered: