In Android using jetpack-compose, is there currently a way to display a text containing links in a @Composable Text?
In legacy TextView, we used Markwon with linkify plugin. Markwon creates a Spanned object that we can set into the TextView's text.
Is there a way to proceed with the same with @Composable Text? Or do we have to use a legacy TextView embedded within a @Composable AndroidView?
Thank you
I think this library can help you: https://github.com/jeziellago/compose-markdown
Add the repository to the project's build.gradle.
Then, add the dependency to the module's build.gradle
and finally, you can use the library as follows:
In this sample, both links are detected.