It would be great if nuxt supports xml format out of the box.
I know I can now use nuxt as middleware for the express. But what I love about nuxt that it just works without any configuration.
How I see it:
there would be
In xml folder we can create as many js files as we want.
Each file is mapped to one route as xml page.
xml\sitemap.js would generate sitemap.xml
xml\merchants.js would generate merchants.xml (google shops format)
In each file there should be exported one function that takes
context and return a
The promise returns xml data.
So nuxt should scan the folder, map the routes and set proper content-type when request come.
Guys, what do you thing about it?