rstoyanchev / spring-websocket-portfolio

740 stars 443 forks source link

Custom error messages on login #76

Open hri101 opened 6 years ago

hri101 commented 6 years ago

While not directly related to the core functionality of the example, I'd like to understand if it is possible to handle custom(server-side) login error messages and visualize such in the "login.html" page using knockout.js. The example's readme says knockout.js is used, also in login.html there is a commented out "div" tag with data-bind="visible: showErrorMessage".

The initial version of the login HTML page used to use knockout: https://github.com/rstoyanchev/spring-websocket-portfolio/commit/e1892031bd2645a7c77d879c460f3a533a97a5ab#diff-00440c40d0495d75cf45cf34a006b10d

Most of the Spring examples for handling login error messages use JSP-s, this one uses HTML+JS. Would someone point me to a working example?

Thanks