kean / Pulse

Network logger for Apple platforms
https://pulselogger.com
MIT License
6.18k stars 294 forks source link

added some form of UIKit Support #241

Closed Mcrich23 closed 4 months ago

Mcrich23 commented 5 months ago

I added 3 functions for UIKit:

  1. UIConsoleViewController is a function that neatly wraps ConsoleView into UIKit, and yes the closeButtonHidden modifier still works (ie. vc. closeButtonHidden(true)
  2. UIConsoleNavigationViewController is two different functions that support navigation before ios 16 and ios 16+. It is the same as UIConsoleViewController, but with a navigation wrapper.
Mcrich23 commented 5 months ago

@kean Thoughts?

kean commented 5 months ago

Hey, @Mcrich23. It's nice to have these convenience methods, but Pulse is primarily designed to be integrated into the existing navigation controllers, so I'm not sure it's worth extending the public API for something relatively trivial. There is also an existing MainViewController, which probably doesn't have the best name – it used to be a MainView counterpart, but it has been removed. It should probably be renamed to ConsoleViewController.

Mcrich23 commented 5 months ago

Ok, that is why both of those controller names exist.

kean commented 4 months ago

Hey, @Mcrich23. I'm going to close the PR if you don't mind and incorporate the changes you suggested but in a slightly different form in the upcoming versions. Thank you for raising this.