Stack Overflow to Devs: Help Us Make Code Better by Example

The number of new tools designed to make life easier for software developers has exploded in recent years. New programming frameworks help you snap applications together more quickly, while open source code libraries help you avoid having to build and rebuild common components. Meanwhile, cloud services make it easy to add features that would be difficult and expensive to build yourself.

But learning how to use all that technology means reading—a lot. Reading reams of documentation can be a real pain, especially if the docs don’t tell you what you need to know. Many developers end up scouring the web for help, and perhaps most often they end up at Stack Overflow, the massively popular site where developers can ask and answer programming questions.

Since its launch in 2008, Stack Overflow has become a crucial source for development help. The company behind the site, Stack Exchange, boasts that 40 million developers visit Stack Overflow per month. Now it wants Stack Overflow to become more than just a place that people go when they get stuck. It wants to be a place for people to find good documentation that may answer their questions before they have to ask them in the first place.

That’s why Stack Overflow Documentation is launching today with the aim of crowdsourcing documentation help from the same community of developers that made its questions and answers site a success. A few big name partners are already hosting some of their own docs with Stack Overflow, including Dropbox, Microsoft, PayPal, and Twitch.

The big question is how to get developers to undertake the onerous task of writing good docs. Stack Overflow vice president Jay Hanlon says the company did quite a bit of research into what developers like to see in documentation. The best way to improve the state of documentation, the team concluded, was to add more examples. “One of the things we kept hearing is was that documentation was generally too focused on syntax and describing things and doesn’t show enough,” he says. “In coding, showing is almost always beats telling.”

Instead of trying to convince volunteers to document an entire software language or framework from scratch, Stack Overflow is instead asking people to provide a good example for each feature of a piece of technology. If you’re familiar with Java’s multithreading, you can provide a small code example to help other people understand it better. Or you can make a good example better by cleaning up the code or adding comments. The idea is that a developer could make a significant contribution in a short period of time, like during a lunch break—a much less daunting prospect than asking them to spend their spare time documenting the entire Java language.

Just as users can vote for which answers they believe are the best on Stack Overflow, users will be able to vote for the code examples they think are best. The people who routinely post the best examples will rack up points as people vote for their work. But, Hanlon says, that’s not the real reason people have historically contributed to Stack Overflow. “Game mechanics have never gotten people to do something that they didn’t want to do in the first place,” he says. “But they can reinforce it.”

Rather, he says, developers have been motivated by the fundamental human drives to help other people and overcome challenges. Better documentation would certainly help a lot of developers. And improving today’s documentation will surely be a challenge.

Επιστροφή...

Update cookies preferences