SwiftUI List optional refreshable

Currently refreshable modifier does not support nil as a value and there's no way of disabling refreshable without recreating the whole view.

There are a few posts showing how refreshable could be optionally disabled on scrollViews using:

 \EnvironmentValues.refresh as? WritableKeyPath<EnvironmentValues, RefreshAction?>

https://stackoverflow.com/a/77587703

However, this approach doesn't seem to work with Lists. Has anyone find any solutions for this?

SwiftUI List optional refreshable
 
 
Q