Missing "./modules" specifier in "swiper" package
notflip opened this issue ยท 8 comments
I updated the package to 1.2.0, coming from a 0.xx version, now I'm getting the error
Missing "./modules" specifier in "swiper" package
My config is
modules: [
'@nuxtjs/i18n', 'nuxt-swiper'
],
swiper: {
modules: ['pagination']
}
@notflip I can't seem to re-produce this on my ENV. Can you make a re-production please ๐๐ผ
The only thing I can think of, is that swiper is not on the latest version that contains /modules
in the package.json
I would try deleting node_modules/
and .lock
file and do a re-install
Happend to me also after I upgraded to Nuxt 3.6.5 via npm upgrade --force
. Removing .lock and node_modules did not resolve the problem.. The error dissapier if I remove the modules from swiper params in nuxt.cofig.
@ShiriCZ Is it possible that you take a screenshot of the exports within the package.json
within node_modules/swiper/package.json
? I can only see this if it is on the incorrect version of swiper
.
Updating to the latest version of Swiper fixed the issue, I was on 8.x.x, I'm not on 10.0.4. Thank you everyone
@notflip nuxt-swiper
should be including this on install. In most cases if you control the swiper version in further releases there might be a high chance of the package breaking.
Glad it helped!
yes, this problem installing:
pnpm why swiper
dependencies:
nuxt-swiper 1.2.2
โโโ swiper 10.3.0
get version https://github.com/cpreston321/nuxt-swiper/blob/main/package.json#L47 and install fixed
pnpm add swiper@10.2.0
done