vue-gallery icon indicating copy to clipboard operation
vue-gallery copied to clipboard

Gallery is broken when navigated to directly

Open jtleniger opened this issue 4 years ago • 4 comments

I have a gallery on a page that works exactly as expected when navigated to from another page, i.e. open mypage.com, click gallery.

If I navigate directly to mypage.com/gallery, the gallery buttons are visible and unstyled, and clicking the images doesn't work.

Nothing appears in the console, and from the inspector it appears that the v-gallery isn't getting registered or something?

Functional, navigating from another page: Screen Shot 2020-04-15 at 11 42 19 AM

Broken, navigating directly: Screen Shot 2020-04-15 at 11 42 00 AM

jtleniger avatar Apr 15 '20 17:04 jtleniger

I'm using in NuxtJS which generates a static site so I'm suspicious this is the issue: Annotation 2020-04-15 184656

jtleniger avatar Apr 16 '20 00:04 jtleniger

Might be a dupe. Seems like this: https://github.com/RobinCK/vue-gallery/issues/3#issuecomment-335893257

jtleniger avatar Apr 16 '20 00:04 jtleniger

Unfortunately setting ssr: false didn’t resolve it.

jtleniger avatar Apr 16 '20 02:04 jtleniger

Encountering a similar issue If I navigate through links on the site it loads perfectly. If I go directly from the URL it breaks with the error 'SyntaxError Invalid or unexpected token'

In console I'm also seeing the same message @jtleniger is getting about server-rendered and client-side DOM tree not matching.

moetun88 avatar Aug 03 '20 04:08 moetun88