You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

react-slide-rule

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-slide-rule

A React component allowing users to select a value along a subjective range and step.

1.1.0
latest
Source
npmnpm
Version published
Weekly downloads
265
-2.93%
Maintainers
1
Weekly downloads
 
Created
Source

react-slide-rule

npm npm

React-slide-rule is a React component shaped like a ruler/slide rule, allowing users to select a value along a subjective range and step.

More demos available here!

examples

Installation

npm install react-slide-rule

Simple example

simple-example

import React, { useState } from 'react';
import SlideRule from 'react-slide-rule';

const STYLE = {
  display: 'flex',
  flexDirection: 'column',
  alignItems: 'center',
};

export default function () {
  const [value, setValue] = useState(150);

  return (
    <div style={STYLE}>
      <p>{value}</p>
      <SlideRule value={value} onChange={setValue} />
    </div>
  );
}

More examples

Check out the example codes in the repository, or demos.

Props

A list of all props available here.

Hint: Use suggestion/auto complete to find the props in your code editor.

License

This project is licensed under the MIT license.

Keywords

react

FAQs

Package last updated on 20 Nov 2023

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