I am trying to figure out a way to extract the text from .epub files, but I am unsure how to do this.
The closest I can get is with epubjs-react-native where I can at least get the epub files to display on the screen.
import * as React from 'react';
import { SafeAreaView, useWindowDimensions } from 'react-native';
import { Reader, ReaderProvider } from '@epubjs-react-native/core';
import { useFileSystem } from '@epubjs-react-native/expo-file-system';
export default function App() {
const { width, height } = useWindowDimensions();
return (
<SafeAreaView>
<ReaderProvider>
<Reader
src="https://s3.amazonaws.com/moby-dick/OPS/package.opf"
width={width}
height={height}
fileSystem={useFileSystem}
/>
</ReaderProvider>
</SafeAreaView>
);
}
But I don't see any way to parse the text. I am open to using another package instead of this one, but this is all I have found so far that isn't outdated.