File tree Expand file tree Collapse file tree 2 files changed +1
-3
lines changed
Expand file tree Collapse file tree 2 files changed +1
-3
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,6 @@ function MyComponent() {
2222 // optionally you can pass options, those are default:
2323 let options = {
2424 throttle: 100 ,
25- passive: true ,
2625 }
2726 let position = useWindowScrollPosition (options)
2827 // position == { x: 0, y: 0 }
Original file line number Diff line number Diff line change @@ -20,7 +20,6 @@ let getPosition = () => ({
2020
2121let defaultOptions = {
2222 throttle : 100 ,
23- passive : true ,
2423}
2524
2625function useWindowScrollPosition ( options ) {
@@ -36,7 +35,7 @@ function useWindowScrollPosition(options) {
3635 window . addEventListener (
3736 'scroll' ,
3837 handleScroll ,
39- supportsPassive && opts . passive ? { passive : true } : false
38+ supportsPassive ? { passive : true } : false
4039 )
4140
4241 return ( ) => {
You can’t perform that action at this time.
0 commit comments