leemartin
*Some* calls to Server API being appended with ".html"
I've mapped out a Server API (integrating with Contentful) based on the Nuxt3 server directory docs. It all seems to be functioning well, most of the time. However, occasionally, I've noticed that ".html" gets appended to the API call, ending in some bad calls or worst misrouting. Have you ever heard of this? So, if I have a route
/messages/[id].get.ts
sometimes it is called as /messages/123.html.get.ts
. I've seen this happen occasionally when calling the API route directly and when calling it via useFetch but there doesn't seem to be a method to this madness. I should mention my site is set to ssr: false
if that makes any difference.5 replies
Redirect based on referring domain
I've developed a Netlify hosted Nuxt app and I'm trying to prevent access to said site depending on the domain users originate from. I realize that is sort of a hack but any simple hacked solution would be fine I think. So, if users go to said site directly, it would redirect them off BUT if they arrive at said site from a particular domain, it would let them through. Any ideas on how to pull this off?
2 replies