struct LePlay: View {
var fileName: String
init(fileName: String) {
self.fileName = fileName
}
@State var player = AVPlayer(url: URL(string: "https://blala.com/?n=" + fileName)!)
I get
Cannot use instance member 'fileName' within property initializer; property initializers run before 'self' is available
in the last fileName
in the code
I've already seen similar questions but none of the solutions there are working for me