cloudinary
cloudinary copied to clipboard
Trouble with SSR
Hi
I have just installed this module and testing it out. One thing I am confused about - is this module SSR ready?
e.g. using
@madsh93 Nuxt is SSR, so this module is for both SSR and static site generating.
e.g. using is only rendered client-side.
I don't quite understand. Can you please elaborate a bit?
@mayashavin Hi Maya
Sorry for the short explanation. My issue is, when I add the module and do the cld-image component tag, the image works great, but it is not displayed when javascript is blocked, therefore I assume it does not work with SSR?
@madsh93 Got it. The current version for components used in this module has a problem with SSR afaik, it rendered 'cld-image' in the html page instead of the actual img tag in SSR. The next version of the Vue components has the fixes for it, and I'm waiting for its release to fully test.
I will suggest to use $image.url
for now if you want it to work when javascript is blocked.
Will keep this issue open and update it :). Hope it helps.
And thanks a lot for reporting it :)
Which version is affected? I'm using v1.0.2 and got this error:
[Vue warn]: The client-side rendered virtual DOM tree is not matching server-rendered content. This is likely caused by incorrect HTML markup, for example nesting block-level elements inside <p>, or missing <tbody>. Bailing hydration and performing full client-side render.
when using the cld-
components.
@Clex1o1 all the versions currently, including the latest - v1.0.3-beta-2
.
@mayashavin Hey Maya. Is this planned for Nuxt 3.0 or 2.15? :-)
@madsh93 currently it's planned for 2.15. But I try to make it compatible with Vue 3x (aka Nuxt 3) if we can't release it before end of March :)
@mayashavin How's it going? Any update on this?
Hi, does this mean that if I generate a nuxt.js website using the static target the cld-image
tag does not work?
Hello, any updates? REALLY need this to be working SSR/SSG.
@johncastorina maybe give a look to nuxt/image
and see if it works there: https://image.nuxtjs.org/providers/cloudinary
I am new to this module...just discovered the SSR issue too.
I wrapped the <cld-
components in <client-only>
for now. Any potential downsides to this?
@haykkh the image will not be available on server side.
@kissu SSR doesn't work so the image isn't available server side anyway though, right?
Indeed.
This is still not resolved? Getting a lot of errors about "The client-side rendered virtual DOM tree is not matching server-rendered content" when using with Nuxt 2.15.7 and cloudinary 1.0.3.
Any update?
Hey, Closing this as it targets the v1 version and it is a really old issue
This one may be helpful too: https://v1.image.nuxtjs.org/providers/cloudinary