Hi all, I had a form created with validation rules that dynamically showed the validation errors etc.
However, since moving this to a SPA, the validation messages no longer appear.
My best guess is that because the page is fetched via XHR, the validation isn’t being bound to the new view. Is there any way to re-trigger this functionality on page load via XHR?
Below you can see my validation fules, but nothing appears in the browser when these rules fail.
Solved - I’d renamed the id on my form to be unique but the onsubmit click handler action hadn’t updated - register.submit() vs registerUser.submit().
All validation is now working
Are there plans for Wappler to do this automatically? It’s often annoying having to track down everything when you do a simple rename (server actions, events etc.)
Updated the title etc. and solution as the main issue here was that the form validation wasn’t working due to the missing dmxValidator lines while converting pages to the SPA approach. No idea how it happened to be honest, but @scott’s post solved it.
I would have thought it would more or less impossible to update everything reliably if changes are made to variable names etc., given that the names themselves could be dynamic.
However, in relation to this, some months ago it was mentioned that you were planning a feature to enable an export in some form containing all the structure and elements used in a project, which, apart from anything else, would help in situations like this (renaming variables etc.). It sounded like a very useful feature. Is this still planned?