unlockagency/radon
Radon is part of the **[E-sites iOS Suite](https://github.com/e-sites/iOS-Suite)**.
Cocoapods
Podfile:
pod 'Radon'And then
pod installManual
Just download the radon binary and put it anywhere you like.
Just run:
$ Pods/Radon/bin/radonWith the following options:
Usage: Pods/Radon/bin/radon [options]
-f, --folder:
The folder to scan
-o, --output:
The folder to write the Radon.swift files to
-w, --watch:
Automatically watch the 'folder'
-r, --remove_foldernames:
Remove the name of the folder from the filenameWith the --watch option the cli app wil automatically scan the folder and generate the Radon files when any changes have been made inside that folder.
So for instance:
$ Pods/Radon/bin/radon --folder ./Resources/ --output ./Classes/Generated/ --watch --remove_foldernamesThis will generate two files:
- Radon.swift
- Radon+images.swift
- Radon+localization.swift
You can use these two files in your project.
See the example project for more information.
Usage
let image = Radon.images.assets.icons.ironMan
let imageView = UIImageView(image: image)
imageView.frame = CGRect(x: 50, y: 50, width: 100, height: 100)
self.view.addSubview(imageView)For your convenience you can also use the shorthand R.swift notation.
typealias R = RadonPackage Metadata
Repository: unlockagency/radon
Default branch: main
README: README.md