Developing Atom Plugins, Part 1: On the Bleeding Edge

12 Oct 2015 by ggreer

Back in February of 2014, GitHub announced their new editor: Atom. We’ve followed Atom since it went public, and recently developed a Floobits plugin for it. What follows are our impressions from the experience.

The History of Atom in 30 Seconds

At the time of its release, Atom was slow, buggy, and lacked basic features. Many wrote it off it as cheap imitation of Sublime Text. In the subsequent 18 months, Atom has improved remarkably. The recent 1.0 release is a powerful, extensible editor suited for everyday use. Atom still isn’t as fast or as stable as Sublime Text, but it’s catching up quickly. Or, to put it more accurately: Sublime Text development has stagnated. Since the first release of Atom, Sublime Text 2 has had zero releases. Sublime Text 3 Beta has had three, one of which was a minor bug fix. Considering the difference in development speed, Atom will almost certainly improve faster than Sublime Text.

Not All Rainbows and Unicorns

That said, Atom’s journey hasn’t been entirely pleasant. Its development process is accurately described by Facebook’s slogan: “Move fast and break things.” Since its initial release, Atom’s API has changed drastically, breaking package compatibility multiple times. Even the license has changed. Most of these changes have been for the better, but keeping up with them requires significant time and effort. Hopefully, things will settle down now that Atom is 1.x.

It’s a Browser… Sort Of

Many of Atom’s detractors point out that it’s based on a browser: Chromium. While this does increase resource usage and startup time, there are significant advantages to building on top of Chromium:

  • Fewer cross-platform issues. Chromium already works well on OS X, Windows, and Linux.
  • Plugins are written using JavaScript, HTML, and CSS. Web developers can quickly learn to extend Atom.
  • Tracking down errors in Atom is much easier than other editors, thanks to Chromium’s debugger. Only IntelliJ has comparable self-debugging abilities.
  • Chromium has browser technologies such as WebRTC, which aren’t available in any other editor or IDE. Floobits for Atom uses WebRTC for video chat. It’s very nice.

Leveraging a browser has advantages and disadvantages, but I think GitHub made the right choice.

A Few Missing Pieces

The Atom devs have done a great job over the past 18 months, but a few conspicuous issues still linger. By far, the most glaring bug is binary safety. If you open a binary file with Atom and save it without making any changes, the file will be corrupted. The only other editor I know that does this is nano.

Another glaring omission is Atom’s lack of GitHub integration. Some extensions are GitHub-specific, but the editor itself has no GitHub features. Built-in GitHub authentication would be useful for many extensions. Instead of setting your GitHub API key/secret in each plugin, Atom could provide it (with appropriate prompting, of course).

Despite these shortcomings, I’ve found myself using Atom more and more. It’s become a very compelling alternative to Sublime Text.

For a more technical discussion of Atom’s current issues, read part 2.

About the Author

I’m Geoff Greer, CEO & co-founder of Floobits.

About Floobits

Floobits lets you collaborate on code like you're in the same room. Think Etherpad or Google Docs, but in Sublime Text, Vim, Emacs, or IntelliJ.

If you're interested, sign up.