Prohibited Interface Builder
Creating views using Interface Builder should be avoided
- Identifier:
prohibited_interface_builder
- Enabled by default: No
- Supports autocorrection: No
- Kind: lint
- Analyzer rule: No
- Minimum Swift compiler version: 5.0.0
- Default configuration:
Key Value severity warning
Non Triggering Examples
class ViewController: UIViewController {
var label: UILabel!
}
class ViewController: UIViewController {
@objc func buttonTapped(_ sender: UIButton) {}
}
Triggering Examples
class ViewController: UIViewController {
@IBOutlet ↓var label: UILabel!
}
class ViewController: UIViewController {
@IBAction ↓func buttonTapped(_ sender: UIButton) {}
}