@@ -159,7 +159,7 @@ To begin, we need to import the modules and their corresponding CSS files from t
159
159
import React from ' react' ;
160
160
import { IonContent , IonPage } from ' @ionic/react' ;
161
161
import { Swiper , SwiperSlide } from ' swiper/react' ;
162
- import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper' ;
162
+ import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper/modules ' ;
163
163
164
164
import ' swiper/css' ;
165
165
import ' swiper/css/autoplay' ;
@@ -191,7 +191,7 @@ From here, we need to provide these modules to Swiper by using the `modules` pro
191
191
import React from ' react' ;
192
192
import { IonContent , IonPage } from ' @ionic/react' ;
193
193
import { Swiper , SwiperSlide } from ' swiper/react' ;
194
- import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper' ;
194
+ import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper/modules ' ;
195
195
196
196
import ' swiper/css' ;
197
197
import ' swiper/css/autoplay' ;
@@ -223,7 +223,7 @@ Finally, we can turn these features on by using the appropriate properties:
223
223
import React from ' react' ;
224
224
import { IonContent , IonPage } from ' @ionic/react' ;
225
225
import { Swiper , SwiperSlide } from ' swiper/react' ;
226
- import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper' ;
226
+ import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper/modules ' ;
227
227
228
228
import ' swiper/css' ;
229
229
import ' swiper/css/autoplay' ;
@@ -272,7 +272,7 @@ We can install the `IonicSlides` module by importing it from `@ionic/react` and
272
272
import React from ' react' ;
273
273
import { IonContent , IonPage , IonicSlides } from ' @ionic/react' ;
274
274
import { Swiper , SwiperSlide } from ' swiper/react' ;
275
- import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper' ;
275
+ import { Autoplay , Keyboard , Pagination , Scrollbar , Zoom } from ' swiper/modules ' ;
276
276
277
277
import ' swiper/css' ;
278
278
import ' swiper/css/autoplay' ;
@@ -425,7 +425,7 @@ Accessing these properties can be tricky as you want to access the properties on
425
425
``` tsx
426
426
import React , { useState } from ' react' ;
427
427
import { Swiper , SwiperSlide } from ' swiper/react' ;
428
- import { Swiper as SwiperInterface } from ' swiper' ;
428
+ import { Swiper as SwiperInterface } from ' swiper/modules ' ;
429
429
...
430
430
const Home: React .FC = () => {
431
431
const [swiperInstance, setSwiperInstance] = useState <SwiperInterface >();
@@ -466,7 +466,7 @@ If you are using effects such as Cube or Fade, you can install them just like we
466
466
``` tsx
467
467
import React from ' react' ;
468
468
import { IonContent , IonPage , IonicSlides } from ' @ionic/react' ;
469
- import { EffectFade } from ' swiper' ;
469
+ import { EffectFade } from ' swiper/modules ' ;
470
470
import { Swiper , SwiperSlide } from ' swiper/react' ;
471
471
472
472
import ' swiper/css' ;
@@ -493,7 +493,7 @@ Next, we need to import the stylesheet associated with the effect:
493
493
``` tsx
494
494
import React from ' react' ;
495
495
import { IonContent , IonPage , IonicSlides } from ' @ionic/react' ;
496
- import { EffectFade } from ' swiper' ;
496
+ import { EffectFade } from ' swiper/modules ' ;
497
497
import { Swiper , SwiperSlide } from ' swiper/react' ;
498
498
499
499
import ' swiper/css' ;
@@ -521,7 +521,7 @@ After that, we can activate it by setting the `effect` property on `swiper` to `
521
521
``` tsx
522
522
import React from ' react' ;
523
523
import { IonContent , IonPage , IonicSlides } from ' @ionic/react' ;
524
- import { EffectFade } from ' swiper' ;
524
+ import { EffectFade } from ' swiper/modules ' ;
525
525
import { Swiper , SwiperSlide } from ' swiper/react' ;
526
526
527
527
import ' swiper/css' ;
0 commit comments