I was trying to get data from one view controller but it didn't work and this happened
import UIKit
import WebKit
class VideoViewController: UIViewController, WKUIDelegate {
var URLParent = VideoChooserViewController(nibName: "ChooseVideo", bundle: nil)
var URL_link=URLParent.YouTubeURL //Error: Cannot use instance member 'URLParent' within property initializer; property initializers run before 'self' is available
var myURL = URL(string: URL_link)
//var webView = WKWebView()
override func viewDidLoad() {
super.viewDidLoad()
}
/*
// MARK: - Navigation
// In a storyboard-based application, you will often want to do a little preparation before navigation
override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
// Get the new view controller using segue.destination.
// Pass the selected object to the new view controller.
}
*/
}