Skip to content
This repository was archived by the owner on Mar 22, 2023. It is now read-only.

unindented/react-puzzle

Repository files navigation

React Puzzle Version Build Status Dependency Status Coverage Status

Sliding puzzle component for React.

Installation

To install the stable version along with React, run the following:

$ npm install --save react-puzzle react

This assumes that you're using the npm package manager with a module bundler like Webpack or Browserify.

If you don't yet use npm or a modern module bundler, and would rather prefer a single-file UMD build that makes ReactPuzzle available as a global object, you can build it yourself by running the following:

$ npm run build

You'll find the development (react-puzzle.js) and production (react-puzzle.min.js) versions of the library in the dist folder. I don't recommend this approach for any serious application.

Usage

import {SlidingPuzzle} from 'react-puzzle'
import {render} from 'react-dom'

render(
  <Puzzle src='http://localhost/image.png' rows={3} cols={3} />,
  document.getElementById('container')
)

Meta

Contributors

License

Copyright (c) 2016 Daniel Perez Alvarez (unindented.org). This is free software, and may be redistributed under the terms specified in the LICENSE file.

About

Sliding puzzle component for React.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •