Single
Explore posts from serversDownload and serve NuxtImg's from /public folder when generating with SSR true
@kapa.ai 1. is actually what i want - does this only work for images being embeded from the public folder? It doesnt seem to work from images being mebded from an external source (directus).
19 replies
Add data to store on Page Refresh
We solve this by using pinia-plugin-persistedstate. It saves the token to the sessionStoreage / localStorage and loads it for you automatically. It has a callback method you can use to request the user for the token from the backend once the store is loaded:
8 replies
Can't get relative paths in `nuxi generate`
It's hard to say without seeing your code. Your reproduction does exactly what it is supposed to do.
./
=> /
, thats why only .
results into relative paths which might work better depending on your provider. I can't tell why this breaks your subpages without seeing the issue.13 replies
Docker and Nuxt in production
You need to expose something. If you do not want to expose the API directly, you can use nitro (nuxt-server) as a proxy. In this case, "only" the server has to be exposed but not the api directly. Does this make sense? I guess not.
7 replies
Docker and Nuxt in production
What we do is, we use a reverse-proxy like https://traefik.io/traefik/ to give managed access to the API and thus expose it to the public.
7 replies
Docker and Nuxt in production
You simply can't. The API call is not being made by the Webserver that is hosting the SSG/Frontend, but the Client (Browser) that visits the site. If this client has no access to the (exposed) API, you can't not do requests against it.
7 replies
<NuxtPage> events?
It feels indeed weird to do that. It might not show errors as the recipient does care if the component ever emits an event called
some-event
but you will have a very hard time to debug this in the future.
I'd say for a quick'n dirty page, okay. In general i would not do that.4 replies