npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

react-responsive-image-carousel

v1.0.2

Published

Wrapper for react-responsive-carousel npm package

Downloads

12

Readme

React Responsive Image Carousel

npm version

React Responsive Image Carousel is a wrapper for leandrowd's react-responsive-carousel package (https://github.com/leandrowd/react-responsive-carousel).

Overview

This package allows the developer to pass in an array of images as a prop, along with any props associated with the react-responsive-carousel package in order to render an image carousel.

Many thanks to https://github.com/leandrowd/ for doing such a great job writing and maintaining the underlying component that this package wraps!

Installation

The package can be installed through npm https://www.npmjs.com/package/react-responsive-image-carousel

$ npm install -S react-responsive-image-carousel

Quick Example

Note: All props allowed by the react-responsive-carousel package can be ingested by the ImageCarousel component. Furthermore, any props required by the react-responsive-carousel package are required by this package.

Please refer to the documentation of the react-responsive-carousel package for additional information (linked at the top of this readme).

import ImageCarousel from 'react-responsive-image-carousel';
class myApp extends React.Component {
    render() {
        const images = ['./pathToImage_1.png', './pathToImage_2.png', './pathToImage_3.png'];
        return (
        <ImageCarousel
            images={images}
            onClickItem={myFunc1}
            onChange={myFunc2}
            onClickThumb={myFunc3}
        />);
    }
}

Run it Yourself

To run the example given in this repository, please follow these steps:

  • Clone this repository to your local environment
  • Install all dependencies by executing $ npm install in your local directory
  • Start your local server by executing $ npm start. This server will run on port 8000
  • Bundle the files in the repository by executing $ npm build
  • Visit http://localhost:8000/client/ to see the example!

TODO:

  • Additional Examples
  • Write unit tests using jest