better route handling for docs