nuxt-swiper icon indicating copy to clipboard operation
nuxt-swiper copied to clipboard

nuxt-swiper is not support ssr:false, Is it a bug?

Open lizyChy0329 opened this issue 10 months ago • 2 comments

when I set ssr: false in nuxt.config.ts, CI show tips:

[error] Nuxt Build Error: [vite]: Rollup failed to resolve import "swiper/css" from "virtual:nuxt:/builds/mfex/ssr-source/goodtime/.nuxt/css.mjs".
This is most likely unintended because it can break your application at runtime.
If you do want to externalize this module explicitly add it to
`build.rollupOptions.external`

util I import swiper/vue instead of nuxt-swiper

lizyChy0329 avatar Apr 24 '24 08:04 lizyChy0329

@lizy0329-biubiubiu please trying using the swiper elements branch on v2.

Docs: https://github.com/cpreston321/nuxt-swiper/tree/feat/elements?tab=readme-ov-file#nuxt-swiper

Install: https://github.com/cpreston321/nuxt-swiper/pull/109

Please let me know if that helps. v1 will soon be deprecated.

cpreston321 avatar Apr 24 '24 15:04 cpreston321

@lizy0329-biubiubiu please trying using the swiper elements branch on v2.

Docs: https://github.com/cpreston321/nuxt-swiper/tree/feat/elements?tab=readme-ov-file#nuxt-swiper

Install: #109

Please let me know if that helps. v1 will soon be deprecated.

Hi, does "v1 will soon be deprecated" mean that we have another v2.x.x nuxt-swiper which supports swiper element (webComponents)? Shall I use this library or I might wait you to publish the v2 version?

Currently, I am struggling in setting up the swiper element with Nuxt3... :(

STY1997 avatar Jul 10 '24 07:07 STY1997