For PHP devs - PHP Storm vs VSCode
Tags: php, ide, vscode, phpstorm
Published: 2020-02-05 10:21:59

---
title: For PHP devs - PHP Storm vs VSCode
published: true
description: A brief look at two top IDEs
tags: php, ide, vscode, phpstorm
---

Yes, I know how the title sounds and it's probably going to get some people riled up over other IDEs but there are some things worth mentioning:

1. I'm a PHP dev but I appreciate and IDE that can help with other stuff reliably. Containers, GIT vizualization, diffs, some UI help and reliably working with other languages are definite pluses.

2. I dislike Atom. It's nice for JS for the most part, but throw anything heavy at it and it slows to a crawl. Also, most plugins I worked with were buggy in mind blowing ways.

3. I like SublimeText 3, but found it unreliable. Collecting PHP dependencies, particularly for 7, working with newer language features, doing stuff like finding interface implementations and so on aren't quite on par with others.

4. VIM - yes, I used to like it. I'm old, I like stuff that just works (as much as possible) without getting sucked into customization and configuration. Give me 3 screens and a VIM configuration sprint and I'm there!

But on to the subject!

## PHPStorm ##

I sort of think of it like a Holy Grail. Yes, it's a commercial product but if your outfit pays for it, it comes with great tooling.

1. Diff tool:
That's the feature I appreciate most about it. It's a clean 3-way merge + diff tool that makes it crystal clear where each change comes from and you can manually edit the outcome. When you're done, everything gets staged so that you can get on with the commit/merge/rebase

2. Debugger:
Pretty awesome XDebug integration. One thing I miss through was to easily control whether to automatically stop on exceptions. Otherwise the UI is pretty nice to on the fly evaluating and watching expressions, breakpoint control, etc - stuff you normally want from such a tool.

3. GIT:
Pretty basic integration. Nothing to write home about. It's there and you can do basic stuff in a basic UI.

4. Refactoring:
I always loved the way PHPStorm keeps up to date with language features. Formatting to standards, finding implementations of abstract functions / interfaces / etc, symbol replacement in project - all work flawlessly

5. Bonuses:
Sadly, nothing to write home about. You get some assistance on JS stuff, basic things like working with Dockerfiles but nothing beyond that. Need Python / Go or  Kubernetes integration? Look elsewhere.


## VSCode ##

Yes, it's Microsoft, but as far as tools go, it's right there at the top. Out of the box support for things like Python, JS/JSX/TypeScript is awesome for something free. Awesome enough to make me get over my Microsoft repulsion.

1. Diff tool:
that's one thing I miss. There are plugins but nothing really nice in the way of PHPStorm. My other favourite tool, Meld, isn't cross-platform so you may need to look for something appropriate

2. Debugger:
The XDebug plugin is awesome, somewhat better than PHPStorm IMHO. The UI might be as nice, but it doesn't get in the way. You have options to automatically break on various error levels, quick breakpoint navigation, quick expression evaluation & watch and exploring all in-scope variables.

3. GIT:
A few classes beyond what PHPStorm can do, the Git Lens plugin rivals most dedicated Git tools. I still prefer GitKraken for third-party integrations but barring those, I stick with Git Lens.

4. Refactoring:
Here it's worth mentioning that the built in PHP support in VSCode is second-class to Intelephense. However, Intelephense itself offers top-notch refactoring tools but for this like reliable symbol replacement and implementation discovery you need to shell out ... roughly 10 USD. Not a bad fee to get the core of what I appreciated about PHPStorm.

5. Bonuses:
Boy, where do I start.
- VSCode comes with top-of-the-class support for popular things like JS/JSX/React/Python/Golang in terms of languages
- Great integration for tools like PowerShell/Bash/Docker/Kubernetes - manage your containers/clusters straight from the IDE!
- one of my favourites is the TODO plugin that indexes all TODO comments from the code and can export them into lists / tasks /etc
- nice things like Bracket Colorizer add some spice to classic bracket matching by coloring bracket pairs with different colors
- font ligatures are awesome! Being able to turn key combinations like => into proper symbols is a nice icing on the cake

I am not entirely sure about VSCode licensing though, is it enterprise friendly?