Skip to content

Instantly share code, notes, and snippets.

@mohsinbmwm3
Created January 18, 2021 15:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mohsinbmwm3/2ba367d74ed3090cde00ad164f08d58a to your computer and use it in GitHub Desktop.
Save mohsinbmwm3/2ba367d74ed3090cde00ad164f08d58a to your computer and use it in GitHub Desktop.
NSNotification extension idea.
import UIKit
extension NSNotification.Name {
static var userLoggedInSuccessfully: NSNotification.Name { NSNotification.Name(rawValue: "userLoggedInSuccessfully") }
static var userLoggedOutSuccessfully: NSNotification.Name { NSNotification.Name(rawValue: "userLoggedOutSuccessfully") }
static var appEnteredInForeground: NSNotification.Name { NSNotification.Name(rawValue: "appEnteredInForeground") }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment