Generate images and colors inside a Swift package

Can also be achieved without casting ImageResource

public extension UIImage {
  static var ad: UIImage {
    .init(resource: .AD)
  }
  static var closedCaptions: UIImage {
    .init(resource: .CC)
  }
  static var movie: UIImage {
    .init(resource: .movie)
  }
  static var notificationPrimerStack: UIImage {
    .init(resource: .notificationPrimerStack)
  }
}

I am interested as well. Have some one achieved it?