There are literally no good reasons to start Visual Studio Code on macOS with leveraged rights. Applications on macOS are not designed to run sudoed in general. If you would do so, this can have unintended sided effects. So much for the disclaimer.
If you want to start Visual Studio Code on macOS sudoed, just run
sudo open /Applications/Visual\ Studio\ Code.app