Sep 4, 2018 · 1 min read
Hi Payal,
Nice stuff!
Just want to know why it hides all my subviews on top of the view like textfields, buttons etc?
If you use
self.layer.insertSublayer(gradientLayer, at: 0)
Then it is added to the back. But also this needs to be added in
override func layoutSubviews()
When the correct frame is set for the view otherwise it shows in the storyboard correctly but doesn’t render on the phone correctly.