voronianski/react-swipe
voronianski/react-swipe has 1,648 GitHub stars and 249 forks. GitHot measured 0 stars in 24 hours and 0 in 7 days. Last checked 2026-11-12 21:30 UTC. Last push 2022-03-22.
:left_right_arrow: Swipe.js as a React component
計測したスター増加
- 24時間
- 0
- 7日間
- 0
- 15日間
- 更新が遅れています
- 1か月
- 更新が遅れています
期間ごとの純増数です。期間は重複しており、日別の値ではありません。未計測の値は空欄です。スター数は注目度の指標であり、品質の保証ではありません。
README.md
オリジナルreact-swipe
Brad Birdsall's Swipe.js as a React component.
Demo
Check out the demo from a mobile device (real or emulated).

Install
npm install react swipe-js-iso react-swipe --save
Usage
Examples
import React from 'react';
import ReactDOM from 'react-dom';
import ReactSwipe from 'react-swipe';
const Carousel = () => {
let reactSwipeEl;
return (
<div>
<ReactSwipe
className="carousel"
swipeOptions={{ continuous: false }}
ref={el => (reactSwipeEl = el)}
>
<div>PANE 1</div>
<div>PANE 2</div>
<div>PANE 3</div>
</ReactSwipe>
<button onClick={() => reactSwipeEl.next()}>Next</button>
<button onClick={() => reactSwipeEl.prev()}>Previous</button>
</div>
);
};
ReactDOM.render(<Carousel />, document.getElementById('app'));
Props
swipeOptions: ?Object- supports all original options from Swipe.js config. If passed object differs from the previous onereact-swipewill re-initiate underlying Swipe.js instance with fresh optionsstyle: ?Object- object with 3 keys (see defaults):container: ?Objectwrapper: ?Objectchild: ?Object
regular props as
className,idfor root component are also supportedchildCount: ?Number- use it to explicitely tellreact-swipethat it needs to re-initiate underlying Swipe.js instance. For example, by setting thechildCountprop to thelengthof the images array that you pass intoreact-swipe, re-rendering will take place when theimages.lengthdiffers from the previousrenderpass:
<ReactSwipe childCount={images.length}>{images}</ReactSwipe>
Methods
Component proxies all Swipe.js instance methods.
Playground
Configure the ReactSwipe component in a sandbox environment at CodeSandbox.
MIT Licensed
関連プロジェクトを探す
freeCodeCamp/freeCodeCamp
freeCodeCamp.org のオープンソースのコードベースとカリキュラムです。数学、プログラミング、コンピュータサイエンスを無料で学べます。
459,077 スターdonnemartin/system-design-primer
大規模システムの設計を学び、システム設計面接の対策ができます。Anki のフラッシュカードが含まれています。
377,748 スターreact/react
Web とネイティブのユーザーインターフェース向けライブラリ。
252,571 スターvuejs/vue
Vue 2 のリポジトリです。Vue 3 については https://github.com/vuejs/core をご覧ください。
212,526 スター