diff --git a/src/StickyParallaxHeader.js b/src/StickyParallaxHeader.js index 47624698..2cc5fc33 100644 --- a/src/StickyParallaxHeader.js +++ b/src/StickyParallaxHeader.js @@ -38,7 +38,7 @@ class StickyParallaxHeader extends Component { } spring = () => { - const scrollNode = this.scroll.getNode() + const scrollNode = this.scroll scrollNode.scrollTo({ x: 0, y: 40, animated: true }) return setTimeout(() => { @@ -51,7 +51,7 @@ class StickyParallaxHeader extends Component { onScrollEndSnapToEdge = (scrollHeight) => { const { snapToEdge } = this.props - const scrollNode = this.scroll.getNode() + const scrollNode = this.scroll // eslint-disable-next-line no-underscore-dangle const scrollValue = this.scrollY.__getValue() const { y } = scrollValue @@ -136,7 +136,7 @@ class StickyParallaxHeader extends Component { }) } if (this.scrollView) { - this.scrollView.getNode().scrollTo({ + this.scrollView.scrollTo({ x: offset, y: 0, animated: true diff --git a/src/components/ScrollableTabView/ScrollableTabView.js b/src/components/ScrollableTabView/ScrollableTabView.js index 8d10c68c..90a542ce 100644 --- a/src/components/ScrollableTabView/ScrollableTabView.js +++ b/src/components/ScrollableTabView/ScrollableTabView.js @@ -43,7 +43,7 @@ class ScrollableTabView extends React.Component { const { children, page } = this.props const { currentPage } = this.state - if (children !== prevProps.children) this.updateSceneKeys({ page: currentPage, children: children }) + if (children !== prevProps.children) this.updateSceneKeys({ page: currentPage, children }) if (page !== currentPage && page >= 0) this.goToPage(page) } @@ -81,7 +81,7 @@ class ScrollableTabView extends React.Component { return ( isHeaderFolded && - scrollRef.getNode().scrollTo({ + scrollRef.scrollTo({ y: scrollHeight, duration: 1000 }) @@ -167,7 +167,7 @@ class ScrollableTabView extends React.Component { const { containerWidth } = this.state const offset = pageNumber * containerWidth if (this.scrollView) { - this.scrollView.getNode().scrollTo({ x: offset, y: 0, animated: true }) + this.scrollView.scrollTo({ x: offset, y: 0, animated: true }) } const { currentPage } = this.state