masspa-carousel
v1.0.4
Published
>
Downloads
11
Readme
masspa-carousel
Install
npm install --save masspa-carousel
Usage
import React, { Component } from 'react'
import MasspaCarousel from 'masspa-carousel'
class Example extends Component {
render () {
return (
<MasspaCarousel />
)
}
}
Properties
| Prop | Description |
| ------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| listBranches
| List branch |
| type
| Type of carousel. Enum [slideThree, slideOne, default]
|
Example
Check full example in the Example
folder.
import React, { Component } from 'react';
import MasspaCarousel from 'masspa-carousel';
import branch1 from './images/branch_01.jpg'
import branch2 from './images/branch_02.jpg'
import branch3 from './images/branch_03.jpg'
import branch4 from './images/branch_04.jpg'
const listBranches = [
{
branchName: 'Chi nhánh Gia Lai',
imageUrl: branch1,
},
{
branchName: 'Chi nhánh Gia Lai',
imageUrl: branch2,
},
{
branchName: 'Chi nhánh Gia Lai',
imageUrl: branch3,
},
{
branchName: 'Chi nhánh Gia Lai',
imageUrl: branch4,
},
]
class Example extends Component {
render() {
return (
<MasspaCarousel
type="slideThree"
listBranches={listBranches}
/>
);
}
}
Demo
Default
slideOne
slideThree
License
MIT © Masspa