Files
dioxus/packages/autofmt/tests/samples/fat_exprs.rsx
T
Jonathan Kelley be99e29e5f Fixes to autofmt, make it more aggressive (#2230)
* fix: fmt unterminated if, be more aggressive with line splits

* Fix: Handle long exprs in for/if statements
2024-04-03 15:27:36 -07:00

32 lines
1.1 KiB
R

//! Exprs that are too long to fit on one line
fn it_works() {
rsx! {
div {
if thing
.some_long_method_that_is_too_long_to_fit_on_one_line()
.some_long_method_that_is_too_long_to_fit_on_one_line()
.some_long_method_that_is_too_long_to_fit_on_one_line({
chain()
.some_long_method_that_is_too_long_to_fit_on_one_line()
.some_long_method_that_is_too_long_to_fit_on_one_line()
})
{
"hi"
}
for item in thing
.some_long_method_that_is_too_long_to_fit_on_one_line()
.some_long_method_that_is_too_long_to_fit_on_one_line()
.some_long_method_that_is_too_long_to_fit_on_one_line({
chain()
.some_long_method_that_is_too_long_to_fit_on_one_line()
.some_long_method_that_is_too_long_to_fit_on_one_line()
})
{
"hi"
}
}
}
}