hi, is there a quick way to display HTML strings i...
# compose
v
hi, is there a quick way to display HTML strings into text ?
t
@Stylianos Gakis is this AnnotedString.fromHtml in the official packages? I do not see where the source code is. It would help a lot.
Ok found it.
s
Yup, I would definitely think twice to use something other than the officially provided solution. I'd at least try that first and if it has any limitations then I'd start looking for alternatives. Haven't used it myself, only knew it exists.
👍 1
c
@Viral Thakker please do not cross post to multiple channels. The “correct” answer might be helpful for others too and like that it might get lost.
Just a short followup we checked the official implementation and it turned out that is is lacking some functionality we need in our project. So maybe if some one has the same experience here is a custom implementation. Maybe it is helpful for some one: https://gitlab.com/-/snippets/3704221
v
@Chrimaeon Sure I'll take care from next time
s
What was lacking Timo?
v
Yes, I tried your reference and it was working like a charm thank you @Stylianos Gakis
👍 1
t
Ok yes all things are support. Only one important thing is missing for us. Defining a base textstyle for the html.
Ok sorry @Stylianos Gakis i checked everything again. And it looks like the official implementation supports everything. Base text style can be applied in the Text composable.
👍 1
So no custom implementation is necessary anymore