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

react-stick

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-stick

React component to stick a portaled node to an anchor node

  • 1.0.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
11K
increased by12.09%
Maintainers
1
Weekly downloads
 
Created
Source

react-stick

CircleCI Coveralls npm package semantic-release

Stick is a component that allows to attach an absolutely positioned node to a statically positioned anchor element. Per default, the node will be rendered in a portal as a direct child of the body element.

npm install --save react-stick
import Stick from 'react-stick'

<Stick node={<p>The sticked node</p>} position="bottom center" align="top center">
  <p>The anchor node</p>
</Stick>

Props

  • children The anchor element
  • node The node to stick to the anchor element
  • position The reference point on the anchor element at which to position the sticked node
  • align The alignment of the sticked node. You can also think of this as the reference point on the sticked node which is placed on the position reference point of the anchor node. For example position="top left" align="bottom right" means "put the bottom right point of the sticked not onto the top left point of the anchor node".
  • inline If set to true, the sticked node will not be rendered detached but inside the same container as the anchor node.

For position and align props string values of the form top|middle|bottom left|center|right are supported.

FAQs

Package last updated on 28 Jan 2018

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