How to get color from Assets.xcassets? [duplicate] How to get color from Assets.xcassets? [duplicate] objective-c objective-c

How to get color from Assets.xcassets? [duplicate]


You should use this init of UIColor

init?(named name: String) 

For example:

view.backgroundColor = UIColor(named: "Greeny")

And your name of Color in Assets must be the same as parameter in init