Inside the RatingsView.swift file, we first need to create all of the variables we will need. Add the following under the class declaration:
let imgFilledStar = #imageLiteral(resourceName: "filled-star")let imgHalfStar = #imageLiteral(resourceName: "half-star")let imgEmptyStar = #imageLiteral(resourceName: "empty-star")let shouldBecomeFirstResponder = truevar rating:CGFloat = 0.0var totalStars = 5
If you copy and paste this code, you will have to select each image to see the actual image. If you are having trouble using an image literal, you can use UIImage(named:) instead.
We are doing something new in this file. We are using image literals as our variables. If you type Image Literal in your ...