Class Swiper

Index

Constructor methods

Properties

Methods

Constructor methods

constructor(container: string, options?: SwiperOptions): Swiper

Parameters

Returns

Swiper

constructor(container: Element, options?: SwiperOptions): Swiper

Parameters

Returns

Swiper

Properties

public activeIndex: number

public activeLoaderIndex: number

public activeLoopIndex: number

public autoplay: boolean

public browser: { ie8: boolean; ie10: boolean; }

public browser.ie10: boolean

public browser.ie8: boolean

public clickedSlide: SwiperSlide

public clickedSlideIndex: number

public height: number

public isTouched: boolean

public params: any

public positions: any

public previousIndex: number

public slides: SwiperSlide[]

public support: { touch: boolean; transforms: boolean; transforms3d: boolean; transitions: boolean; }

public support.touch: boolean

public support.transforms: boolean

public support.transforms3d: boolean

public support.transitions: boolean

public touches: any

public width: number

Methods

public activeSlide(): SwiperSlide

Returns

SwiperSlide

public appendSlide(html: string, slideClassList?: string, element?: string): SwiperSlide

Parameters

  • html: string
  • slideClassList?: string optional
  • element?: string optional

Returns

SwiperSlide

public appendSlide(slideInstance: HTMLElement): SwiperSlide

Parameters

  • slideInstance: HTMLElement

Returns

SwiperSlide

public createSlide(html: string, slideClassList?: string, element?: string): SwiperSlide

Parameters

  • html: string
  • slideClassList?: string optional
  • element?: string optional

Returns

SwiperSlide

public destroy(removeResizeEvent?: boolean)

Parameters

  • removeResizeEvent?: boolean optional

public getFirstSlide(): SwiperSlide

Returns

SwiperSlide

public getLastSlide(): SwiperSlide

Returns

SwiperSlide

public getSlide(index: number): SwiperSlide

Parameters

  • index: number

Returns

SwiperSlide

public getWrapperTranslate(axis: string): number

Parameters

  • axis: string

Returns

number

public insertSlideAfter(index: number, html: string, slideClassList?: string, element?: string): SwiperSlide

Parameters

  • index: number
  • html: string
  • slideClassList?: string optional
  • element?: string optional

Returns

SwiperSlide

public insertSlideAfter(index: number, slideInstance: HTMLElement): SwiperSlide

Parameters

  • index: number
  • slideInstance: HTMLElement

Returns

SwiperSlide

public prependSlide(html: string, slideClassList?: string, element?: string): SwiperSlide

Parameters

  • html: string
  • slideClassList?: string optional
  • element?: string optional

Returns

SwiperSlide

public prependSlide(slideInstance: HTMLElement): SwiperSlide

Parameters

  • slideInstance: HTMLElement

Returns

SwiperSlide

public reInit(forceCalcSlides?: boolean)

Parameters

  • forceCalcSlides?: boolean optional

public removeAllSlides()

public removeLastSlide(): boolean

Returns

boolean

public removeSlide(index: number): boolean

Parameters

  • index: number

Returns

boolean

public resizeFix(reInit?: boolean)

Parameters

  • reInit?: boolean optional

public setWrapperTransition(duration: any)

Parameters

  • duration: any

public setWrapperTranslate(x: number, y: number, z: number)

Parameters

  • x: number
  • y: number
  • z: number

public startAutoplay()

public stopAutoplay()

public swipeNext(internal?: boolean): boolean

Parameters

  • internal?: boolean optional

Returns

boolean

public swipePrev(internal?: boolean): boolean

Parameters

  • internal?: boolean optional

Returns

boolean

public swipeReset(): boolean

Returns

boolean

public swipeTo(index: number, speed?: number, runCallbacks?: boolean): boolean

Parameters

  • index: number
  • speed?: number optional
  • runCallbacks?: boolean optional

Returns

boolean

public updateActiveSlide(index: number)

Parameters

  • index: number

public wrapperTransitionEnd(callback: () => void, permanent: boolean)

Parameters

  • callback: () => void
  • permanent: boolean