Skip to content

Latest commit

 

History

2 提交

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

仓库 files navigation

AssetsCodeGenerator

Converting images folder to Images.xcassets and corresponding swift code. Image file names must end with scale, like ic_jike@2x.png.

Usage

  1. To generate Images.xcassets and code from given images folder, run:
swift GenerateAssetsAndCode.swift -i Images -assetsOutput Output/Images.xcassets -codeOutput Output
  1. Drag Images.xcassets and R.generated.swift to your project
  2. In your code:
let imageView = UIImageView(image: R.images.ic_jike)

关于

Converting images folder to Images.xcassets and corresponding swift code.

Resources

Stars

14 stars

关注者

0 watching

复刻s

发布

贡献者

Languages