Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bee-carousel

Package Overview
Dependencies
Maintainers
15
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bee-carousel

Swiper ui component for react

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
15
decreased by-16.67%
Maintainers
15
Weekly downloads
 
Created
Source

npm version Build Status Coverage Status dependencies Status NPM downloads Average time to resolve an issue Percentage of issues still open

react bee-carousel component for tinper-bee

Carousel 可自定义手动点击滑动和左右滑动,可兼容移动端。基于swiper.js开发.继承swiper.js的所有方法和属性。

依赖

  • react >= 15.3.0
  • react-dom >= 15.3.0
  • prop-types >= 15.6.0

使用方法

import React from 'react';
import Carousel from 'bee-carousel';

class Demo1 extends React.Component {
  render() {
    const params = {
      pagination: {
        el: '.swiper-pagination',
        clickable: true,
      },
      spaceBetween: 30
    }

    return(
      <Carousel {...params}>
        <div>Slide 1</div>
        <div>Slide 2</div>
        <div>Slide 3</div>
        <div>Slide 4</div>
        <div>Slide 5</div>
      </Carousel>
    )
  }
}

export default Demo1;

ReactDOM.render(Demo1, document.getElementById('target'));

API

参数说明类型默认值
containerClassCarousel 容器 class nameStringswiper-container
wrapperClassCarousel 父元素 class nameStringswiper-wrapper
slideClassCarousel 单个元素 class nameStringswiper-slide
prevButtonCustomizedClassCarousel 前一个按钮 class nameString''
nextButtonCustomizedClassCarousel 下一个按钮 class nameString''
paginationCustomizedClassCarousel 页码 class nameString''
shouldSwiperUpdate当元素发生变是否更新CarouselBooleafalse
rebuildOnUpdate当元素更新是否重新渲染CarouselBooleanfalse
noSwiping根据条件是否禁用滑动Booleanfalse
activeSlideKey定义最初的激活态slideString or Number''

你也可以直接用swiper.js的原始参数 这里api/

开发调试
$ npm install -g bee-tools
$ git clone https://github.com/tinper-bee/bee-carousel
$ cd bee-carousel
$ npm install
$ npm run dev

Keywords

FAQs

Package last updated on 24 Apr 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc