Flutter Flavours Blog #2
shahzadafridi
started this conversation in
Blog
Replies: 3 comments
@Composable
fun SpannableText(
modifier: Modifier = Modifier,
annotatedString: AnnotatedString = AnnotatedString(text = ""),
style: TextStyle = primaryLableStyle,
onClickAction: (String) -> Unit
) {
ClickableText(
modifier = modifier,
style = style,
text = annotatedString,
onClick = { offset ->
annotatedString.getStringAnnotations(offset, offset)
.firstOrNull()?.let { span ->
onClickAction.invoke(span.item)
}
})
}
|
0 replies
0 replies
|
Article has been published: https://www.realtimecoding.com/blog/flutter/mastering-your-flutter-app-deep-dive-into-flavors |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment



















Uh oh!
There was an error while loading. Please reload this page.
Post the blog there with correct styling
All reactions