Skip to content

Releases: dotcore64/react-stay-scrolled

v9.0.0

01 May 08:11
ba51d14
Compare
Choose a tag to compare

Breaking: drop node 16
add node 22 support

v8.0.1

01 Feb 06:47
3b82911
Compare
Choose a tag to compare

fix build badge

v8.0.0

31 May 14:15
ed2a89c
Compare
Choose a tag to compare
  • Drop CJS and UMD builds (ESM only)
  • Drop IE support
  • Require Node.js >= 14
  • Add React 18 support

v7.4.0

07 Nov 17:04
ef35ebb
Compare
Choose a tag to compare

Make this module esm-first and hybrid commonjs

v7.3.1

04 Jun 02:56
13263a3
Compare
Choose a tag to compare

Fix typescript options definition

v7.3.0

24 Dec 07:10
9f88d6b
Compare
Choose a tag to compare
  • Add typescript typings

v7.2.0

24 Dec 04:58
33b5402
Compare
Choose a tag to compare
  • Support react@17
  • Upgrade all dependencies

v7.0.0

08 May 16:36
Compare
Choose a tag to compare
  1. runScroll no longer accepts dom as a first argument. If needed, use the ref.current from the component instead.
  2. Add tests and examples of usage with react-spring

v6.0.0

14 Mar 15:27
Compare
Choose a tag to compare

Replaces onScrolled with a new function returned by the hook, isScrolled. Whereas before you'd do:

useStayScrolled(ref, { onScrolled: () => console.log('Scrolled down') });

Now you do:

const ref = useRef();
const { isScrolled } = useStayScrolled(ref);

const onScroll = () => {
  if(isScrolled()) {
    console.log('Scrolled down');
  }
};

return <div ref={ref} onScroll={onScroll} />;

v5.0.0

13 Mar 15:10
Compare
Choose a tag to compare

Removes redundant onStayScrolled option. stayScrolled now returns true when it scrolls, false otherwise.