Ideally you want to learn about a potential candidate's design/coding/debugging/bug-fixing/testing skills. Github project collaboration over a week or so would go a long way towards that.
But you also want to see how well the potential employee communicates with other members of the team, on a day-to-day basis. Some Developers, even good developers, have strong opinions that might rub other employees the wrong way. The key is to look at how well they work as a team.
Having them spend a day or so onsite with your existing team is invaluable. You might also want to consider paying them a nominal amount for the amount of time they would spend on the project. That just adds a professional touch to the whole experience.