Constraintlayout inside Framelayout a red flag? :t...
# android
j
Constraintlayout inside Framelayout a red flag? 🤔
google 1
stackoverflow 1
l
It's totally okay. That said, this is not Kotlin related.
j
Copy code
fun sayThanks() {
   print("Thanks Louis")
}
sayThanks()
😄 1
w
Is it unnecessary most of the time though? What would be the use case?
a
j
My use case was needing to set a constraintDimensionRatio on some views.
l
How does that require to nest the ConstraintLayout in a FrameLayout?
j
Well constrainLayout lets you set the ratio on the view, nesting it in Framelayout allows you to work with fragments
l
From what you're now saying, it seems you're actually doing the opposite: having a
FrameLayout
inside a
ConstraintLayout
, which is also fine.
👍 1