Issue
I want to strikethrough a Text
in Android Jetpack Compose. I have checked some documentation but I still don't find something that looks to what I want to achieve.
https://developer.android.com/jetpack/compose/text
This is my Text component:
Text("$863",fontSize = 24.sp, modifier = Modifier.width(IntrinsicSize.Min), maxLines = 1)
This is what I want to achieve:
Can any one please help me or give me any idea?
Solution
Add style for text
@Composable
fun textWithLineThroughExample(){
Text(
text = "Text with LineThrough",
style = TextStyle(textDecoration = TextDecoration.LineThrough)
)
}
Answered By - Tippu Fisal Sheriff