Content-Length: 362390 | pFad | http://github.com/siteline/swiftui-introspect/discussions/231

6B Question: Keeping UIView instances outside the closure · siteline swiftui-introspect · Discussion #231 · GitHub
Skip to content

Question: Keeping UIView instances outside the closure #231

Closed Answered by davdroman
oriolpregona asked this question in Q&A
Discussion options

You must be logged in to vote

@oriolpregona this is totally fine. I use an approach similar to yours for UINavigationController in my https://github.com/davdroman/swiftui-navigation-transitions library.

As a side note, note there's a newly released module that you should if possible prefer using, as follows:

import SwiftUIIntrospect

ScrollView {
    MyListView()
}
.introspect(.scrollView, on: .iOS(.v13, .v14, .v15, .v16), .tvOS(.v13, .v14, .v15, .v16)) { scrollView in
    self.myScrollView = scrollView
}

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
1 reply
@davdroman
Comment options

Answer selected by davdroman
Comment options

You must be logged in to vote
2 replies
@davdroman
Comment options

@davdroman
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #230 on June 02, 2023 11:51.









ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/siteline/swiftui-introspect/discussions/231

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy