HydrogenReporter icon indicating copy to clipboard operation
HydrogenReporter copied to clipboard

Remove restriction to only show in DEBUG mode

Open 1c3f0x84 opened this issue 1 year ago • 3 comments

Can you please remove the restriction to only show the DebugView only in DEBUG configuration.

1c3f0x84 avatar Feb 29 '24 08:02 1c3f0x84

What would be the benefit of removing the DEBUG mode flags when the debug level is selected? Logs tagged with higher levels will appear in non-debug modes. You can also change your default logging level by setting a log config.

ActuallyTaylor avatar Feb 29 '24 17:02 ActuallyTaylor

No, i want to use the debug view in our inhouse app, but i can't to that, because of this DebugView:

var body: some View {
        if Config.isDebug && showingSelf {
            internalBody
        } else {
            EmptyView()
        }
    }

and in Config

    public static var isDebug: Bool {
        #if DEBUG
        return true
        #else
        return false
        #endif
    }

The DebugView is only visible in debug build configuration.

I only want to show the DebugView in Release Build.

1c3f0x84 avatar Mar 04 '24 08:03 1c3f0x84

Ahh I get what you are looking for. This is something that I can get together this weekend. If you can get it done earlier it would be great if you can make a PR to solve the problem.

ActuallyTaylor avatar Mar 04 '24 16:03 ActuallyTaylor