File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
Sources/YCoreUI/Protocols Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 9
9
import Foundation
10
10
import UIKit
11
11
12
+ /// Any named image asset can be loaded from an asset catalog
13
+ ///
14
+ /// All properties and functions have default implementations. At a minimum just have your string-based enum conform
15
+ /// to `ImageAsset` (and have an asset catalog with matching assets). If your enum and assets live inside a Swift
16
+ /// package, override `bundle` to return `.module`. If your assets are categorized within their asset catalog by
17
+ /// a namespace, then override `namespace` to return the proper string prefix.
12
18
public protocol ImageAsset : RawRepresentable where RawValue == String {
13
19
/// The bundle containing the image assets for this enum (default is `.main`)
14
20
static var bundle : Bundle { get }
You can’t perform that action at this time.
0 commit comments