Connect with us

Code

RichEditor – Android WYSIWYG Rich editor for Jetpack Сompose

RichEditor – Android WYSIWYG Rich editor for Jetpack Сompose.

RichEditor Features

The editor offers the following options:

  •  Bold
  •  Italic
  •  Underline
  •  Different Heading

How to add RichEditor in your project

Add the dependency

 implementation 'com.canopas.editor:rich-editor-compose:X.X.X'

How to use ?

@Composable
fun Sample() {

        val context = LocalContext.current
        
        val state = remember {
            val input = /* YOUR INPUT */
            RichEditorState.Builder()
                .setInput(input)
                .adapter(JsonEditorParser())
                .build()
        }

        RichEditor(
                state = state,
                modifier = Modifier
                    .fillMaxWidth()
                    .weight(1f)
                    .border(1.dp, Color.Gray)
                    .padding(5.dp)
            )
    
}

Demo

Sample app demonstrates how simple the usage of the library actually is.

Bugs and Feedback

For bugs, questions and discussions please use the Github Issues.

Credits

RichEditor for compose is owned and maintained by the Canopas team. For project updates and releases, you can follow them on Twitter at @canopassoftware.

ComposeRichEditor: https://github.com/MohamedRejeb/Compose-Rich-Editor

RichEditor on GitHub: https://github.com/canopas/rich-editor-compose
Platform: Android
⭐️: 24
Advertisement

Trending