5-stones / react-native-readium

📚 📖 React Native ebook reader for iOS, Android, & Web via Readium
MIT License
83 stars 25 forks source link

feat(android, ios, ontableofcontents): update onTableOfContents to re… #18

Closed jspizziri closed 1 year ago

jspizziri commented 1 year ago

…turn Locator[] for consistency

Links and Locators are not the same and need to be handled differently. To avoid complexity, the library has been update to only deal with Locators and map all Links it returns to Locators.

BREAKING CHANGE: onTableOfContents now returns a Locator[] instead of a Link[]. Update your onTableOfContents callbacks from (toc: Link[]) => {...} to (toc: Locator[]) => {...}.

https://github.com/5-stones/react-native-readium/issues/11

jspizziri commented 1 year ago

Closing, as this is not the correct solution.