NativeScript / NativeScript/angular
angular 14+ modal back navigation issue
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 55
- Forks
- 13
- Avg merge
- 16m
- Merged PRs (30d)
- 1
Description
Environment
- CLI: 8.4.0
- Cross-platform modules: 8.4.0
- Android Runtime: 8.4.0
- iOS Runtime: 8.4.1
- NativeScript-Angular: 14+
- Angular: 14+
After closing a modal (contains page-router-outlet) in the second screen and navigating back to Home Screen, then automatically runs a new Home Screen navigation.
I checked with the navigationTo event: it fires like forward navigation too.
navigatedTo event in Home Screen after closing modal and navigating back (event fires twice):
- isBackNavigation: false
- isBackNavigation: true
This happens on android and on ios.
The latest version of Angular 13 and @nativescript/angular 13 is working fine, but nothing above it.
Sample project
https://github.com/BalintVegh/ns-angular-modal-issue
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked sample project and reproduce closing the modal, returning to Home Screen, and the duplicate navigation events on Angular 14+ and NativeScript-Angular 14+. Compare the behavior with Angular 13, and consider the issue resolved when back navigation no longer triggers an extra Home Screen navigation or duplicate events on Android and iOS.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- angular, typescript
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100