在 xcode 11.4.1 中,资产文件夹中的图像出现此错误 "Use of unresolved identifier",这是为什么?

In xcode 11.4.1 I get this error "Use of unresolved identifier" for an image which is in assets folder, why is that?

import UIKit

class ViewController: UIViewController {

    let canoaimageview: UIImageView = {
        let imageview = UIImageView(image: canoa) //ERROR Use of unresolved identifier 'canoa'

        imageview.translatesAutoresizingMaskIntoConstraints = false
       return imageview
}()

  override func viewDidLoad() {
          super.viewDidLoad()


    view.addSubview(canoaimageview)
    setupLayout()
    }

    private func setupLayout() {
    canoaimageview.centerXAnchor.constraint(equalTo: view.centerXAnchor).isActive = true
    canoaimageview.topAnchor.constraint(equalTo: view.topAnchor, constant: 100).isActive = true
    canoaimageview.widthAnchor.constraint(equalToConstant: 150).isActive = true
    canoaimageview.heightAnchor.constraint(equalToConstant: 150).isActive = true
    }


}

//包含显示错误和资产文件夹的附加图像

你需要先制作一个UIImage,然后像这样赋值给imageView

    let canoaimageview: UIImageView = {
        let imageview = UIImageView(image: UIImage(named: "canoa")) //ERROR Use of unresolved identifier 'canoa'
        imageview.contentMode = .scaleAspectFit
        imageview.translatesAutoresizingMaskIntoConstraints = false
       return imageview
}()