wingsuit-designsystem / wingsuit

Twig for Storybook
GNU General Public License v2.0
92 stars 16 forks source link

How to replace swiper library #84

Closed GiorgosK closed 3 years ago

GiorgosK commented 3 years ago

Swiper library is a really huge library and as we already discussed in slack you are OK with replacing it. I have tried to add a new library to replace swiper

cd starter-kits/tailwind
yarn add tiny-swiper

but I get this error

error An unexpected error occurred: "expected workspace package to exist for \"jsonfile\"".

when adding with npm

npm install tiny-swiper --save

it works but the library cannot be imported

// starter-kits/bootstrap/source/default/patterns/03-organisms/slider/slider.behavior.js
import Swiper from 'tiny-swiper';

leads to

Unable to resolve path to module 'tiny-swiper'

What am I missing ? I see that swiper is included in more than one package.json but not familiar with multiple packages repositories (perhaps this is what I am missing)

christianwiedemann commented 3 years ago

You propably have to downgrade yarn to 1.19. There is an open issue for yarn. I added an yarn.rc to the project.

christianwiedemann commented 3 years ago

Replaced with glide.js