Skip to content

Commit

Permalink
Reset Progress on Chapter End (Closes #791)
Browse files Browse the repository at this point in the history
  • Loading branch information
rajarsheechatterjee authored and CD-Z committed Jan 10, 2024
1 parent c30266e commit 7b54ec6
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/screens/reader/ReaderScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -363,9 +363,10 @@ const ChapterContent = ({ route, navigation }) => {
};
}, [position?.percentage]);

const scrollToSavedProgress = useCallback(() => {
scrollTo(position?.position);
}, []);
const scrollToSavedProgress = useCallback(
() => scrollTo(position?.position),
[],
);

const chapterText = useMemo(
() =>
Expand Down

0 comments on commit 7b54ec6

Please sign in to comment.