how to call a function to another view controller swift code example
Example: how to call another view controller method when button click from another ios swift
NotificationCenter.default.addObserver(self, selector: #selector(disconnectPaxiSocket(_:)), name: Notification.Name(rawValue: "disconnectPaxiSockets"), object: nil)