Declare your QRScannerController class first...
...then add the extension code, like this:
class QRScannerController: UIViewController {
var video = AVCaptureVideoPreviewLayer()
var qrcodeFrameView = UIView() // this needs to be initialized to something
override func viewDidLoad() {
super.viewDidLoad()
// creating session
let session = AVCaptureSession()
}
}
extension QRScannerController: AVCaptureMetadataOutputObjectsDelegate {
// add delegate methods here...
}
Try this:
guard let url = URL(string: "https://www.google.com") else {return}
Otherwise, "myWebView" must be nil.
You could add a diagnostic message, before the error line...
print("myWebView: \(myWebView)")
So our users think they can share our subscription in their family.
but I'm talking about Family sharing for the app itself, not for in-app subscriptions
It's a free app, so anyone can download it, for free.
"Family Sharing" is for sharing the subscription.
Apple say:
You can now enable Family Sharing for auto-renewable subscriptions and non-consumable in-app purchases, allowing users to share their purchases with up to five family members
Apple say:
Please note that once you turn on Family Sharing for an in-app purchases in App Store Connect, you cannot turn it off.
See https://help.apple.com/app-store-connect/#/dev45b03fab9
...so you may need to create a new subscription, with Family Sharing turned off.
There is a new option called "Unlisted app distribution", which might suit your case.
The app is not listed on the App Store, and is made available by distributing a direct link.
See: https://developer.apple.com/support/unlisted-app-distribution/
There are a number of ways you could do this...
I would drop the RoundedRectangle, and use the Image as the navigation link
Give it some padding
Set the background color
Set the corner radius
NavigationLink(destination: EmptyView()) {
Image(systemName: "heart.fill")
.padding(100)
.background(Color.red)
.cornerRadius(25)
}
Alternatively, if you want to keep the RoundedRectangle (for some other reason) use a ZStack, like this:
NavigationLink(destination: EmptyView()) {
ZStack {
RoundedRectangle(cornerRadius: 25)
.fill(Color.red)
Image(systemName: "heart.fill")
}
}
Declare your QRScannerController class first...
...then add the extension code, like this:
class QRScannerController: UIViewController {
var video = AVCaptureVideoPreviewLayer()
var qrcodeFrameView = UIView() // this needs to be initialized to something
override func viewDidLoad() {
super.viewDidLoad()
// creating session
let session = AVCaptureSession()
}
}
extension QRScannerController: AVCaptureMetadataOutputObjectsDelegate {
// add delegate methods here...
}
Try this:
guard let url = URL(string: "https://www.google.com") else {return}
Otherwise, "myWebView" must be nil.
You could add a diagnostic message, before the error line...
print("myWebView: \(myWebView)")
So our users think they can share our subscription in their family.
but I'm talking about Family sharing for the app itself, not for in-app subscriptions
It's a free app, so anyone can download it, for free.
"Family Sharing" is for sharing the subscription.
Apple say:
You can now enable Family Sharing for auto-renewable subscriptions and non-consumable in-app purchases, allowing users to share their purchases with up to five family members
Apple say:
Please note that once you turn on Family Sharing for an in-app purchases in App Store Connect, you cannot turn it off.
See https://help.apple.com/app-store-connect/#/dev45b03fab9
...so you may need to create a new subscription, with Family Sharing turned off.
There is a new option called "Unlisted app distribution", which might suit your case.
The app is not listed on the App Store, and is made available by distributing a direct link.
See: https://developer.apple.com/support/unlisted-app-distribution/
There are a number of ways you could do this...
I would drop the RoundedRectangle, and use the Image as the navigation link
Give it some padding
Set the background color
Set the corner radius
NavigationLink(destination: EmptyView()) {
Image(systemName: "heart.fill")
.padding(100)
.background(Color.red)
.cornerRadius(25)
}
Alternatively, if you want to keep the RoundedRectangle (for some other reason) use a ZStack, like this:
NavigationLink(destination: EmptyView()) {
ZStack {
RoundedRectangle(cornerRadius: 25)
.fill(Color.red)
Image(systemName: "heart.fill")
}
}