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

react-image-tiler

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-image-tiler

A responsive image tiling component for React

  • 1.1.5
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
5
decreased by-72.22%
Maintainers
1
Weekly downloads
 
Created
Source

Image Tiler

screencast

Image tiler is a React component that displays images in a responsive, tiled layout.

Installation

$ npm install react-image-tiler

Configuration

The Tiler component has the following properties:

  • images - an array of image URLs to display
  • minWidth - the minimum width of an image
  • maxWidth - the maximum width of an image
  • parentWidth - a function returning the pixel width of a parent. By default, it's window.innerWidth

Use

import React from 'react'
import ReactDOM from 'react-dom'
import Tiler from 'react-image-tiler'

images = [
    'http://placekitten.com/300/300',
    'http://placekitten.com/300/300',
    'http://placekitten.com/300/300',
    'http://placekitten.com/300/300',
]

ReactDOM.render(<Tiler images={images} minWidth="200" />, document.getElementById('foo'))

Example

See example/index.html.

The example also includes a very simple InstagramFeed class that makes it easy to pull a public feed of images from someone's Instagram account. It's used in the example/index.jsx example, and also on my website

Development

$ npm run example

Keywords

FAQs

Package last updated on 07 Mar 2017

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