donut industries

A Brief Opinion on Sublime Text

About 5 or 6 years ago I switched from TextMate to Sublime Text. I didn’t have a terribly good reason to switch, except that I loved the layout and the dark-by-default theme. Since then I’ve used IntelliJ IDEA Ultimate (extremely powerful but takes up a ton of resources), RubyMine (perhaps one of the reasons I live Ruby), and Atom (I tried it for 2 weeks when it first came out, but eventually dropped it). But in all my swaying I have inevitably come back to Sublime Text.

What, then, makes a great code editor for web development? I think it largely comes down to the following must haves:

  • a distraction free layout - a code editor should do one thing fundamentally really, really well, and that’s to get out of the way and to let you edit code. Sublime Text is simple, yet polished. it does what it needs to do and you forget you’re even using it.
  • extensability - the modern web developer likely works in a plethora of languages and has things to deal with like version control, code linting, and wants to save keystrokes. Sublime Text has a HUUUUUUUUGE collection of packages to help you do your job ‘mo betta.
  • speed, brilliant speed - if your code editor is slowing you down you will quickly become frustrated with it. it’s no wonder your friendly neighborhood programmer genius uses vim/emacs. it’s fast. Sublime is fast too… but right inside your GUI.

And so it’s for these reasons I constantly come back to Sublime Text. I can hide the sidebar and ignore the directory structure without little UI elements reminding me that it’s still hidden there. I can layout files in a horizontal or vertical grid with unobtrusive tabbing still available. I have git and ruby built-ins to help me figure out what I am actually doing in code. Then it does all this with tremendous speed. No waiting for IntelliJ or RubyMine to index or for the non-native editing from Atom.

And then there’s the extensibility. Here are my favorite packages for Sublime Text:

GitGutter

GitGutter is like JetBrains’ annotate, but the light beer version, just for Sublime. It shows you symbols for the diff between whatever branch you choose as your base, right in the gutter. The symbols are also customizable.

SublimeLinter-jshint

It does what it says. It provides a package for SublimeLinter to interface with jshint so you can keep your JavaScript squeaky clean.

SublimeLinter-rubocop

Oh, I didn’t forget about ruby. SublimeLinter-ruboCop runs some good ol’ static analysis on your code right inside of Sublime Text.

Emmet

If you’re like me, you’re pretty ridiculous about spitting out good HTML. Emmet let’s you expand HTML from CSS-like syntax. It’s pretty amazeballs.


Needless to say, I think Sublime Text is Sublime, and there’s so many other packages out there that will complement the way you want to write code. Feel free to share your favorite packages, key bindings, and snippets with me over on the twitter machine: @donutindustries