Skip to content

How to hide tabbar in subview #330

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

You must be logged in to vote

By default, .introspect works directly on its receiver. This means calling .introspect from inside the view you're trying to introspect won't have any effect. This is different to the original Introspect module in which some views would implicitly allow introspection from within. You can introspect an ancestor with SwiftUIIntrospect, but you must opt into this explicitly by overriding the introspection scope:

import SwiftUI
import SwiftUIIntrospect

@propertyWrapper
final class Weak<T: AnyObject> {
    private weak var _wrappedValue: T?

    var wrappedValue: T? {
        get { _wrappedValue }
        set { _wrappedValue = newValue }
    }

    init(wrappedValue: T? = nil) {
        self._…

Replies: 1 comment 1 reply

Comment options

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

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

This discussion was converted from issue #329 on August 15, 2023 14:55.