- Allow React v18 in
package.json
.
- Add
children
prop to TypeScript definitions forWaypoint
to support React v18.
- Classes are now compiled in loose mode, which should improve runtime performance.
- Babel helpers now import from
@babel/runtime
instead of being inlined, which reduces bundle size.
- [Breaking] Remove
Waypoint.getWindow()
- Support React 17
- Make waypoints work with
overflow: overlay
- Remove StrictMode warnings
- Fix export in TypeScript types (#298)
- Update babel 6 -> 7, rollup 0 -> 1 (#301)
- [Breaking] Require React 15.3+
- [Breaking] Make Waypoint a named export instead of default export
- Change constants into named exports for better minification
- Fix removing propTypes in production builds
- Ensure that children is valid only in dev
- Fix isForwardRef call
- Improve support for refs (#278)
- Don't include
.babelrc
in published npm package (#270)
- Defer
handleScroll
incomponentDidUpdate
(#265) - Extend
React.PureComponent
instead ofReact.Component
when available (#264)
- Allow consolidated-events ^2.0.0 (#256)
- Add message to better understand logged error message in tests (#255)
- Fix default export error in typescript definition file
- Add es module entry point in package.json
- Type Waypoint class properties as static
- Let proptypes be removable in consumers production bundles
- Fix second arg to Typescript component definition
- Add second arg to Typescript component definition
- Fix typescript definition
- Make es module opt in (via
import Waypoint from 'react-waypoint/es'
)
- Build with rollup.
- Add an ES module build.
- Allow React 16 as a peerDependency.
- Remove scrollableParent prop check error.
- Add support for using composite components as child (#208)
- Update consolidated-events from 1.0.1 to 1.1.0.
- Fix bug in onNextTick.
- Fix bug if waypoint updates before being initialized.
- Improve startup time by consolidating
setTimeout
s and deferring work until the initial timeout happens.
- Move
prop-types
to a regular dependency - Assume
window
as scrollable ancestor when<body>
hasoverflow: auto|scroll
- Restrict lower bound of React to v0.14.9
- Add
prop-types
as a peer dependency to remove deprecation warnings when running on React 15.5
- Remove the
prop-types
peer dependency. This was an accidental breaking change that will instead be released as 6.0.0.
- Remove deprecation warnings when running on React 15.5
- Add React 14 to Travis test suite.
- [Fix] Avoid unnecessary clearTimeout when unmounting.
- [New] scrollableAncestor prop can now accept "window" as a string. This should help with server rendering.
- Debug code is now minified out in production build.
- Waypoint can now accept children.
- Clear initial timeout when unmounting component.
- Revert ES6 typescript definition.
- Fix typescript definition to support ES6 imports
- [Breaking] Remove
throttleHandler
- Add typescript definitions file
- Add
horizontal
prop. Use it to make the waypoint trigger on horizontal scrolling.
- Delay initial calling of handleScroll when mounting.
- Extract event listener code to consolidated-events package.
- Prevent event listeners from leaking.
- Fix error when a waypoint unmounts another waypoint as part of handling a (scroll/resize) event.
- [Breaking] Use passive event listeners in browsers that support them. This
will break any Waypoint event handler that was calling
event.preventDefault()
. - Initialize fewer event listeners.
- Avoid warnings from React about calling PropTypes directly (#119).
This version contains a fix for errors of the following kind:
Unable to get property 'getBoundingClientRect' of undefined or null reference
- Fix passing props to super class, to make react-waypoint compatible with preact (thanks @kamotos!)
New properties have been added to the onEnter
/onLeave
/onPositionChange
callbacks:
waypointTop
- the waypoint's distance to the top of the viewport.viewportTop
- the distance from the scrollable ancestor to the viewport top.viewportBottom
- the distance from the bottom of the scrollable ancestor to the viewport top.
- Change
threshold
tobottomOffset
andtopOffset
- Add
throttleHandler
prop to allow scrolling to be throttled
- Added
debug
prop
- Improved position calculation
- Add React 15 support
- Breaking: Unify arguments passed to callbacks
- Add
displayName
- Handle invisible waypoint parents
- Add
onPositionChange
- Rename
scrollableParent
prop toscrollableAncestor
- Simplify
getWindow
usage - Allow any
scrollableParent
- Add
fireOnRapidScroll
prop
- Make bundled waypoint.js easier to import
- Upgrade Babel from 5 to 6
- Convert from CommonJS to ES2015 modules
- Convert from React.createClass to ES2015 class
- Remove bower support
- Calculate proper offset when or has a margin
- Fix built version
- Add statics for edge argument used by
onEnter
andonLeave
- Prevent scroll handler from blowing up if the component is not mounted at the time of execution
- Add second parameter to
onEnter
andonLeave
callbacks to indicate from which direction the waypoint entered from and to respectively
- Prevent duplicate onError/onLeave callbacks
- Prevent error when
<html>
has a scrollable overflow styling
- Bump
react
dependency to 0.14 and addreact-dom
topeerDependencies
- Replace
this.getDOMNode()
withReact.findDOMNode(this)
- Improve support for scrolling very quickly
- Add event object and scope to onEnter/onLeave calls
- Allow React 0.14.0-beta peerDependency
- Always remove window resize event listener
- Ignore more files for bower and npm packages
- Commit the built version for bower package
- Add 'jsx' syntax to the unbuilt version of the component, and build into 'build/ReactWaypoint.js' with webpack.
- Fix corner case where scrollable parent is not the window and the window resize should trigger a Waypoint callback.
- Fix Waypoints with the window element as their scrollable parent (Firefox only)
- Fix Waypoints with the window element as their scrollable parent
- Change default threshold from 0.1 to 0
- Guard against undefined scrollable parent when unmounting
- Initial release