AEM Spa editor - Error Page handling
One of the questions we frequently got from customers was on how to handle 404 / 500 pages in the SPA editor. Unfortunately we could not give a good answer, and it required a lot of hacking to make it work. Thats why just now, we updated the spa page model manager to support handling 404 / 500 pages! It works like this: Page Request is made and ACS AEM error handler catches it. Client tries to fetch a model JSON but get's a 404 error in return. Client now will take the error page root (given as meta property) and use the status code to make a new request. Presuming the page exists, the authored error page model JSON is injected as requested path. The error page is displayed. Result: Check out the repository providing a demo: https://github.com/niekraaijmakers/aem-spa-editor-errorpages-example happy coding!