Socket
Book a DemoInstallSign in
Socket

cohan-react-scrollspy-ez

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cohan-react-scrollspy-ez

simple scrollspy component for react

latest
Source
npmnpm
Version
1.0.4
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

react-scrollspy-ez

simple scrollspy component for react

NPM JavaScript Style Guide

Demo

here

Install

npm install --save react-scrollspy-ez

Usage

import * as React from "react";

import Scrollspy from "react-scrollspy-ez";

class Example extends React.Component {
  render() {
    return <Scrollspy ids={["one", "two"]} />;
  }
}

Options

  • ids - dom id of the page element to track
  • offset - scroll offset (in pixels), if your page elements have lots of padding. Default is 2.
  • itemContainerClassName - class for the whole scrollspy menu
  • activeItemClassName - class for the active menu item
  • containerElement - a JSX element for the whole menu (default is ul)
  • itemElement - a JSX element for each menu item, default is li

License

MIT © telega

FAQs

Package last updated on 22 Jan 2021

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