Is there a way to easily remove layouts like Colum...
# compose
y
Is there a way to easily remove layouts like Column, Row, or Box in Android Compose, similar to how it's done in Flutter with options like 'Remove this widget'? Currently, I have to manually remove them, and I only see 'Surround with Widget' as an option. Is there no similar shortcut or method in Android Compose?
🚫 1
👌 1
a
Not that I know of but I do it using the keyboard. option + up or down to increases the scope
if you select the whole composable you can then start an other scope by pressing Shift + {
y
Oh... but exactly what I want is just removing only
FlowRow
not
Box
in case of your video.
a
what i do in that case is select the box and its contents then cut, then remove the flow row then paste
k
1. put the cursor on openning
{
2.
Unwrap action
Ctrl+Shift+Delete (Cmd+Shift+fn+Backspace on Mac)
👍 1
image.png
k
For this functionality I'm using composetool plugin in intelij. https://plugins.jetbrains.com/plugin/23053-composetool
k
for colours there is https://plugins.jetbrains.com/plugin/21298-compose-color-preview other features are available out-of-the-box
today i learned 1
y
@Konstantin Tskhovrebov Thank you! The shortcut works fine! (Cmd+Shift+fn+Backspace on Mac)
s
@Konstantin Tskhovrebov Whoa that's actually pretty awesome! Thanks! Makes me wonder how many other gems does IntelliJ hide :D
k