Skip to content

Ginioo/img-carousel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@ginioo/simple-carousel

a simple carousel for images or else

  1. install
npm i -D @ginioo/simple-carousel
  1. add ImageCarousel to a component
import React, {Component} from 'react';
import {ImageCarousel} from '@ginioo/simple-carousel';

class SampleComponent extends Component {

  render() {
    return (
      <div id="sample">
        // default slide to the right
        <ImageCarousel src="http://via.placeholder.com/350x150" />
        
        <ImageCarousel slide="left" src={[
            "http://via.placeholder.com/350x150",
            "http://via.placeholder.com/350x150",
        ]} />
      </div>
    );
  }
}

export default SampleComponent;
  1. define #simple-carousel height and width
#simple-carousel {
  width: 1024px;
  height: 440px;
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published