We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello @victorsoares96
I used one of your example Formats, in this example base64 is not working, loader keep on loading.
Formats
https://github.com/victorsoares96/epubjs-react-native/blob/master/example-bare/examples/Formats/index.tsx
Android, iOS
Bare Workflow
bare
No response
The text was updated successfully, but these errors were encountered:
It working now, needed to add data:application/oebps-package+xml;base64, prefix
data:application/oebps-package+xml;base64,
But application is very slow, when I swipes to next page, it takes around 2min to navigate, is there any solution ?
This is my code
import React, {useEffect, useState} from 'react';
import { SafeAreaView, Text, Button } from 'react-native'; import { Reader, useReader } from '@epubjs-react-native/core'; import { useFileSystem } from '@epubjs-react-native/file-system'; // for Bare React Native project import { Annotations } from './Annotation'; import { Bookmarks } from './Bookmarks'; import { BookmarksList } from './Bookmarks/BookmarksList'; import Toc from './TableOfContents'; // import { useFileSystem } from '@epubjs-react-native/expo-file-system'; // for Expo project import ExampleE from './../../src/components/baseSF/base64' import { Formats } from './Formates'; var RNFS = require('react-native-fs');
export default function Epub() { const [basesf, setBasesf] = useState(null); function onPressLearnMore() { RNFS.readFile(RNFS.ExternalStorageDirectoryPath+ "/clinic/another.txt").then((res)=>{ setBasesf(res) }).catch(err=> console.log(err)) }
useEffect(()=>{ console.log('FILE WRITTEN! 2', basesf) }, [basesf])
if(!basesf){ return <Button // onPress={()=>onPressLearnMore_(RNFS.ExternalStorageDirectoryPath+ "/clinic/example.epub")} onPress={onPressLearnMore} title="Learn More" color="#841584" accessibilityLabel="Learn more about this purple button" /> }
return ( <SafeAreaView style={{ flex: 1 }}> <Reader src = {"data:application/oebps-package+xml;base64,"+basesf} fileSystem={useFileSystem} width={"100%"} height={700} /> ); }
Sorry, something went wrong.
No branches or pull requests
Summary
Hello @victorsoares96
I used one of your example
Formats
, in this example base64 is not working, loader keep on loading.https://github.com/victorsoares96/epubjs-react-native/blob/master/example-bare/examples/Formats/index.tsx
What platform(s) does this occur on?
Android, iOS
What workflow(s) does this occur on?
Bare Workflow
Environment (or package.json)
bare
Your .epub file
No response
Minimal reproducible example
No response
I confirm that i have
The text was updated successfully, but these errors were encountered: