by extension: git history
reference:
how-to-compare-different-branches-in-visual-studio-code
It's now possible by using the githistory extension.
Here's a small trick though: You can compare the latest commits from each branch and that would be the same as comparing two branches side by side or creating a PR.
Here's how to do that using githistory extension:
1. Open githistory
2. Pick the latest commit from your current branch by clicking on "Git Commit Icon" → (Usually it should be latest commit it the list). From the opened dropdown menu click on "Select this commit".
3. Pick the latest commit from the branch you want to compare to by clicking "Git Commit Icon".
4. As a result, the dropdown should appear with a few options → Select the last option that says "Compare with SHA" and you'll see the diff.
cmd+shift+p => git history => Pick the branch which you want to diff in left => click button “more” => select this commit … =>
Pick the branch which you want to diff in right => click button “more” => compare with … =>
you will see “compare commits” in the bottom on explorer