\n \u003CNavbar :language=\"language\" />\n \u003CNuxtPage :language=\"language\" />\n \u003CFooter :language=\"language\" />\n\u003C/template>\n// some other code\n```\n\nReproduction as a project: https://stackblitz.com/edit/github-nprqx2?file=layouts%2Fdefault.vue,error.vue,app.vue,pages%2Findex.vue,.gitignore\n\n### Describe the bug\n\nThe error message does not appear on the page unless I remove `\u003CNuxtLayout name=\"default\">` and `\u003C/NuxtLayout>` from error page. This is not what I want, I want error message inside the layout. I can achieve this by replacing `\u003CNuxtPage>` with `\u003Cslot>`, but that causes other problems (probably because props don't pass into the slot – should I make another bug report for that too?).\n\n### Additional context\n\nUsing a layout on an error page is supposed to work because documentation states:\n\n> you can still use layouts in the error file, by utilizing the [NuxtLayout](https://nuxt.com/docs/api/components/nuxt-layout) component and specifying the name of the layout\n\nBut I haven't found an example of that working. I am not 100% sure it's a bug, maybe I missed something.\n\n### Logs\n\n_No response_",[2008],{"name":1984,"color":1985},29284,"Using layout on error page causes error info to not appear","2024-10-05T18:46:02Z","https://github.com/nuxt/nuxt/issues/29284",0.5955594,{"labels":2015,"number":2021,"owner":1990,"repository":1990,"state":1991,"title":2022,"updated_at":2023,"url":2024,"score":2025},[2016,2019,2020],{"name":2017,"color":2018},"stale","ffffff",{"name":1984,"color":1985},{"name":1987,"color":1988},7014,"Splitted layout with error page","2023-01-22T15:34:48Z","https://github.com/nuxt/nuxt/issues/7014",0.5982133,{"description":2027,"labels":2028,"number":2030,"owner":1990,"repository":1990,"state":1991,"title":2031,"updated_at":2032,"url":2033,"score":2034},"hi \r\n \"nuxt\": \"^2.4.0\"\r\n\r\n my error component in layouts directory :\r\n\r\n```\r\n\u003Ctemplate>\r\n \u003Cdiv class=\"__nuxt-error-page\">\r\n \u003Cdiv class=\"error\">\r\n {{message}}\r\n \u003C/div>\r\n \u003C/div>\r\n\u003C/template>\r\n\r\n\u003Cscript>\r\n export default {\r\n layout: 'empty',\r\n name: 'error',\r\n props: {\r\n error: {\r\n type: Object,\r\n default: null\r\n }\r\n },\r\n\r\n computed: {\r\n statusCode() {\r\n return (this.error && this.error.statusCode) || 500\r\n },\r\n message() {\r\n return this.error.message || `Error`\r\n }\r\n }\r\n }\r\n\u003C/script>\r\n```\r\n\r\nand empty layout : \r\n\r\n\r\n```\r\n\r\n\u003Ctemplate>\r\n \u003Cnuxt/>\r\n\u003C/template>\r\n\r\n\u003Cscript>\r\n\r\n export default {\r\n name: \"empty\",\r\n }\r\n\u003C/script>\r\n```\r\n\r\n\r\nbut when i have error , error component use another layout .. for example, when I'm on the dashboard layout and an error occurs, error component mount on dashboard layout\r\n\r\n\n\n\u003C!--cmty-->\u003C!--cmty_prevent_hook-->\n\u003Cdiv align=\"right\">\u003Csub>\u003Cem>This question is available on \u003Ca href=\"https://cmty.app/nuxt\">Nuxt\u003C/a> community (\u003Ca href=\"https://cmty.app/nuxt/nuxt.js/issues/c9154\">#c9154\u003C/a>)\u003C/em>\u003C/sub>\u003C/div>",[2029],{"name":1987,"color":1988},5654,"error page layout not correctly applied","2023-01-18T20:12:59Z","https://github.com/nuxt/nuxt/issues/5654",0.60141397,{"labels":2036,"number":2041,"owner":1990,"repository":1990,"state":1991,"title":2042,"updated_at":2043,"url":2044,"score":2045},[2037,2040],{"name":2038,"color":2039},"enhancement","8DEF37",{"name":1987,"color":1988},6699,"Add client option to not replace current page component with \u003CNuxtError> component when there's an uncaught error","2023-02-14T11:37:17Z","https://github.com/nuxt/nuxt/issues/6699",0.6014487,{"description":2047,"labels":2048,"number":2059,"owner":1990,"repository":1990,"state":1991,"title":2060,"updated_at":2061,"url":2062,"score":2063},"Initially I declared my default layout using `\u003Cslot>` for router-views because that's what was [recommended in the documentation](https://nuxt.com/docs/guide/directory-structure/layouts#default-layout). This worked but I noticed that the error page does not get the layout. Even [this](https://nuxt.com/docs/guide/directory-structure/layouts#overriding-a-layout-on-a-per-page-basis) and this:\r\n```\r\n\u003Cscript setup lang=\"ts\">\r\n// You might choose this based on an API call or logged-in status\r\nconst layout = \"default\";\r\n\u003C/script>\r\n\r\n\u003Ctemplate>\r\n \u003CNuxtLayout :name=\"layout\">\r\n \u003CNuxtPage />\r\n \u003C/NuxtLayout>\r\n\u003C/template>\r\n```\r\ndid not change the problem that the error page didn't get the layout. This is the first bug in my opinion. So I did a workaround:\r\n```\r\n\u003Cscript setup lang=\"ts\">\r\nimport type { NuxtError } from '#app'\r\nimport DefaultLayout from \"/layouts/default.vue\"\r\nconst props = defineProps({\r\n error: Object as () => NuxtError\r\n})\r\n\u003C/script>\r\n\u003Ctemplate>\r\n \u003CDefaultLayout>\r\n \u003Cdiv>\r\n \u003Ch1>{{ \"Error \" + error?.statusCode }}\u003C/h1>\r\n \u003Cpre>{{ JSON.stringify(error, null, 4) }}\u003C/pre>\r\n \u003CNuxtLink to=\"/\">Go back home\u003C/NuxtLink>\r\n \u003C/div>\r\n \u003C/DefaultLayout>\r\n\u003C/template>\r\n```\r\nThis was ugly but worked however eventually I noticed another problem. I tried passing props from layout to page components and that wasn't working (second bug). So I fixed (?) the problem by replacing `\u003Cslot>` on the layout with `\u003CNuxtPage />`. This again worked but I faced another problem: Now the error page content (other than layout) isn't visible. So now the \"best\" choice I know I have is to have an error page without a layout, but that's not what I want. Do you confirm my bug reports? What should I do? Thanks.",[2049,2052,2053,2056],{"name":2050,"color":2051},"3.x","29bc7f",{"name":1984,"color":1985},{"name":2054,"color":2055},"needs reproduction","FBCA04",{"name":2057,"color":2058},"closed-by-bot","ededed",25982,"Layout issues (error page, slot/NuxtPage props)","2024-12-21T23:06:42Z","https://github.com/nuxt/nuxt/issues/25982",0.60555005,{"description":2065,"labels":2066,"number":2069,"owner":1990,"repository":1990,"state":1991,"title":2070,"updated_at":2071,"url":2072,"score":2073},"\u003C!-- 💚 Thanks for your time to make Nuxt better with your feedbacks 💚\r\n\r\n**IMPORTANT** Before reporting a bug:\r\n\r\n- Please make sure that you have read through Nuxt documentation: https://nuxtjs.org\r\n- If issue is related to a module please create the issue in corresponding repository\r\n- Ensure using latest version of nuxt dependencies using `yarn upgrade nuxt` or `npm upgrade nuxt`\r\n\r\n👍 A properly detailed bug report can save a LOT of time and help fixing issues as soon as possible.\r\n-->\r\n\r\n### Versions\r\n\r\n- nuxt: v2.14.12\r\n- node: v10.16.3\r\n\r\n### Reproduction\r\n\r\n\u003C!--\r\nLink to a minimal test case based on one of:\r\n- A fork of https://template.nuxtjs.org\r\n- A GitHub repository that can reproduce the bug\r\nWithout a reproduction, it is so hard to address problem :(\r\n-->\r\n\r\n\u003Cdetails open>\r\nServer error page often appears, like this.\r\n\r\n I want to know the reason, why server error appears, and how can I avoid this page? Is it the client to change the configuration, or the server to optimize the interface?Thanks!\r\n\u003Cbr>\r\n\u003C!-- Attaching `nuxt.config`, dependencies, logs or code snippets would help to find the issue -->\r\n\u003C/details>\r\n\r\n",[2067,2068],{"name":1984,"color":1985},{"name":1987,"color":1988},8919,"Server error page","2023-01-22T15:38:48Z","https://github.com/nuxt/nuxt/issues/8919",0.6057336,{"labels":2075,"number":2078,"owner":1990,"repository":1990,"state":1991,"title":2079,"updated_at":2080,"url":2081,"score":2082},[2076,2077],{"name":1984,"color":1985},{"name":1987,"color":1988},6651,"bug: error layout not applied properly when error isnt plain object","2023-01-22T15:34:46Z","https://github.com/nuxt/nuxt/issues/6651",0.6139601,{"description":2084,"labels":2085,"number":2087,"owner":1990,"repository":1990,"state":1991,"title":2088,"updated_at":2089,"url":2090,"score":2091},"This is similar to #2120 \r\n\r\nI was trying to make a 404 page that I can serve using Nginx. I was able to do that using `./pages/404.vue`. But I found that the router was still serving up `NuxtError` when vue-router 404 errors occurred.\r\n\r\nI [found the following the docs for the errors pages](https://github.com/nuxt/docs/blob/master/en/guide/views.md#error-page) but I was unable to actually get them working.\r\n\r\nI created a layout exactly as it described but still, nothing happened. My original 404 would work fine (`404.html` from `./pages/404.vue`) if I went to something like `missing.html` but would redirect to the default `NuxtError` component for all other router 404s.\r\n\r\nI then read the source and found that there is an undocumented option called `ErrorPage` that is available in `nuxt.config.js`. This property points to a component to use when there is an error or it will fall back to `./components/nuxt-error.vue`.\r\n\r\nI added an entry to my config for `ErrorPage` and pointed it to a new component I made at `./components/ErrorPage.vue`. After that, everything worked perfectly.\r\n\r\nSo I guess my concern is that either the docs are wrong, or there is a bug in nuxt that doesn't serve the `./layouts/errors.vue` properly.\r\n\r\nAnyone else having this issue?\n\n\u003C!--cmty-->\u003C!--cmty_prevent_hook-->\n\u003Cdiv align=\"right\">\u003Csub>\u003Cem>This question is available on \u003Ca href=\"https://nuxtjs.cmty.io\">Nuxt.js\u003C/a> community (\u003Ca href=\"https://nuxtjs.cmty.io/nuxt/nuxt.js/issues/c1931\">#c1931\u003C/a>)\u003C/em>\u003C/sub>\u003C/div>",[2086],{"name":1987,"color":1988},2188,"Incorrect documentation or bug with errors.vue?","2023-01-18T15:43:11Z","https://github.com/nuxt/nuxt/issues/2188",0.6156923,["Reactive",2093],{},["Set"],["ShallowReactive",2096],{"TRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"zrLkmJxa5zlkZSX_2HG9RGMRSfFEdzKf_OqhhnpVktI":-1},"/nuxt/nuxt/7743"]