Package Exports
- react-remove-scroll-bar
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (react-remove-scroll-bar) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
react-remove-scroll-bar
Removes scroll bar (by setting overflow: hidden
on body), and preserves the scroll bar "gap".
Read - it just makes scroll bar invisible.
Does nothing if scroll bar does not consume any space.
Usage
import {RemoveScrollBar} from 'react-remove-scroll-bar';
<RemoveScrollBar /> -> no scroll bar
The Right Border
To prevent content jumps position:fixed elements with right:0
should have additional classname applied.
It will just provide a non-zero right, when it needed, to maintain the right "gap".
import {zeroRightClassName,fullWidthClassName} from 'react-remove-scroll-bar';
// to set `right:0` on an element
<div className={zeroRightClassName} />
// to set `width:100%` on an element
<div className={fullWidthClassName} />
Size
500b after compression (excluding tslib).
Scroll-Locky
Extracted react-scroll-locky
License
MIT