react-dragless

0.2.1 • Public • Published

react-dragless

A super simple, fancy react component, making images literally undraggable

npm version PRs Welcome Dependency Status Build Status code style: prettier

Installation

yarn add react-dragless

Usage

The draggable way

import React from 'react';
import { render } from 'reactDOM';

render(
  <img src="https://pi.tedcdn.com/r/pe.tedcdn.com/images/ted/0ef62e4df27b4ba7294de889fdbc33e476a08ec9_254x191.jpg?" />,
  document.getElementById('root')
);

Live Example

The swagger way

import React from 'react';
import { Render } from 'reactDOM';
import Static from 'react-dragless';

render(
  <Static
    image={
      'https://pi.tedcdn.com/r/pe.tedcdn.com/images/ted/0ef62e4df27b4ba7294de889fdbc33e476a08ec9_254x191.jpg?'
    }
  />,
  document.getElementById('root')
);

Play around with the source code

Live deployed example

Help Wanted!

If you are a vscode guy, please fork a way to implement debugging, since i haven't configured any debugging at all.

Readme

Keywords

none

Package Sidebar

Install

npm i react-dragless

Weekly Downloads

2

Version

0.2.1

License

MIT

Last publish

Collaborators

  • jimfilippou