Ios swift – CALayer disappears when storing in a property
I have a custom UIPresentationController in which I overrode the presentedView as follows: override var presentedView: UIView? { guard let view = super.presentedView else { return nil } let shadowLayer = CALayer() shadowLayer.shadowPath = .init(rect: view.bounds, transform: .none) shadowLayer.shadowRadius =…