0.0.7 • Published 3 years ago
@apprush/react-native-editor v0.0.7
react-native-editor
A rich text editor for react native. Supports Draft.js and Markdown.
Copied source code from https://github.com/vobi-io/markdown-editor
Installation
yarn add @apprush/react-native-editor
Usage
<SafeAreaView style={{ flex: 1 }}>
<Container>
<KeyboardAwareView keyboardShouldPersistTaps animated>
<View style={styles.editor}>
<TextEditor
ref={(e) => {
editor = e
}}
data={contentState}
onChange={this.onChange}
extraData={this.state.extraData}
/>
</View>
<TextToolbar />
</KeyboardAwareView>
</Container>
</SafeAreaView>
To Do
- Convert from Draft.js contentState
- Convert to Draft.js contentState
- Convert from Markdown
- Convert to Markdown
- Bold
- Italic
- Underline
- Strikethrough
- Move line up & down
- Bullets (Unordered List)
- Numbered List (Ordered List)
- Blockquote
- Heading 1
- Heading 2
- Heading 3
- Font colors
- Tables
- Insert images
- Intends