Cannot convert 'ViewController.Type' to 'UIViewController in Facebook shareDialog
03:02 25 Sep 2018

I think this is outdated on Facebook swift documentation and it is giving errors. I fixed the first line error but it is giving error in viewcontroller line

I am facing this error

Cannot convert value of type 'ViewController.Type' to expected argument type 'UIViewController'

Please somebody give a fix.

import FacebookShare

    let content = LinkShareContent(url: 
    NSURL("https://developers.facebook.com")) //Fixed :- let content = LinkShareContent(url: URL(string: "https://developers.facebook.com")!)


try ShareDialog.show(from: myViewController, content: content)  //Error :- Cannot convert value of type 'ViewController.Type' to expected argument type 'UIViewController'
swift