[Ionic v4] Reactive form reloads the page on submitting
See original GitHub issueBug Report
Ionic Info
Run ionic info
from a terminal/cmd prompt and paste the output below.
Ionic:
ionic (Ionic CLI) : 4.0.0-rc.13 (C:\Users\##\AppData\Roaming\npm\node_modules\ionic)
Ionic Framework : @ionic/angular 4.0.0-beta.0
@angular-devkit/core : 0.7.0-rc.3
@angular-devkit/schematics : 0.7.0-rc.3
@angular/cli : 6.0.8
@ionic/ng-toolkit : 1.0.0
@ionic/schematics-angular : 1.0.0
Cordova:
cordova (Cordova CLI) : 8.0.0
Cordova Platforms : none
System:
Android SDK Tools : 25.2.5
NodeJS : v8.11.3 (C:\Program Files\nodejs\node.exe)
npm : 5.6.0
OS : Windows 10
Environment:
ANDROID_HOME : C:\Program Files (x86)\Android\android-sdk
Describe the Bug Reactive forms not working as expected in ionic v4 beta. When submitting the form it reloads the page instead, it should just submit the form values.
Steps to Reproduce Steps to reproduce the behavior:
- Go to ‘https://reactive-form-bug.stackblitz.io/login’
- Fill form fields / leave empty
- Click on ‘submit’
- Page reloads
Related Code StackBlitz.
Expected Behavior Submitting the form it should just submit the form values.
Issue Analytics
- State:
- Created 5 years ago
- Comments:6
Top Results From Across the Web
Ionic-5, Reactive Form, refresh the page on submit
On click of Submit, it refresh the page. Anyone suggestion pls for this. I don't want click event in button. ionic-framework.
Read more >FormSubmit doesn't update value without refresh page
When I submit my form, the values are updated well but not reactive. I have to refresh the page to see the modification....
Read more >How to Create a (Reactive) Form using Ionic Framework
Learn how to use Ionic Framework components and Angular's Reactive Forms to display a form in your application, capture, and validate its ...
Read more >Submit a Form Without Page Refresh Using jQuery - Code
A great way to improve the user experience of your website is to validate and submit forms without a page refresh.
Read more >Angular 9 Reactive Forms On Submit Reloading The Route
With reactive forms, we can add validation to the fields and access their When we click on the submit button, Angular will catch...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hello there,
I’m having the same issue.
I may have found something :
If I use
The page is reloading when clicking on the button
But, If I use
Then, my submit function is called.
Hope this will helps !
Cheers
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.