You can use the extension ms-vscode.cpptools
to Switch Header/Source
.
- If you’re on Mac, then the shortcut is ⌥ O (option + O key).
- On Windows, the shortcut is Alt+O.
Old answer:
There are currently a couple of extensions that support header/source file toggling:
bbenoist.togglehs
ryzngard.vscode-header-source
You can find more by searching the words “switch toggle header source” in the extensions tab in vscode.