Releases: wellyshen/react-cool-inview
Releases · wellyshen/react-cool-inview
v3.0.1
- Fix: expose
InView
type (#792)
v3.0.0
💥 Breaking Change
- Use named export instead of default export to import the hook.
- import useInView from "react-cool-inview";
+ import { useInView } from "react-cool-inview";
✨ New Feature
- Supports
InView
component, see the example to learn more (thanks to @max-sym)
v2.0.9
- Fix: only setState when active/mounted (#736)
v2.0.8
- Fix: correct the type of
root
(#672).
v2.0.7
Refactor(types): enhance the types of event properties (#561)
v2.0.6
- Refactor(types): export more types to fulfill your use cases (#558)
v2.0.5
- Refactor(types): simplify generic variable
- const { observe } = useInView<HTMLDivElement | null>();
+ const { observe } = useInView<HTMLDivElement>();
v2.0.4
- Fix: infinite re-rendering (#521) (#520)
v2.0.3
- Fix: the values of the
scrollDirection
will sync with the scrolling direction of the viewport, see doc (#499)
v2.0.2
- Fix: align the values of the
scrollDirection
with the direction of the viewport (#499)
- Fix: un-observe the previous target element when updating the new target element via the
observe
API (#500)