Since Swift files don't have a header, it can quickly get cluttered and hard to see just the public
and internal
methods that represent the interface of that file/class.
Xcode actually generates an interface file that can be found by clicking the Assistant Editor
, then selecting the Counterparts
type and you'll see the MySwiftFile.swift (Interface)
file that you can check out.
Does anyone know an easier way to access this interface file? Maybe with a shortcut? I can't seem to find it using Cmd+Shift+O or other means.
Click the assistant editor (use the shortcut Cmd+Option+Enter to show the editor) and thereafter use Ctrl+Cmd+→ or ← to navigate to your .swift
interface file in the assistant window. It's not an immediate short-cut, but possibly better than navigation by clicks/mouse/touchpad.
Open generated interface: Cmd+Ctrl+↑
Go back: Cmd+Ctrl+←
In no way, except for menu selection "Navigate / Jump to Generated Interface"
Xcode cannot assign key binding to "Jump to Generated Interface"
Allow to switch between Swift generated interface and original source via shortcut
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With