In order to use asset pipeline available for static error pages (like 404.html), a few steps are required
-
Move static pages from /public into /app/assets
(eg: public/422.html → app/assets/html/422.html.erb)
-
Add html directory to the asset pipeline
-
Update exceptions middleware to understand assets with digests