docs: function(permalink) {
      permalink = permalink || '';
      if (permalink.slice(0, 1) !== PATH_SEP) {
        permalink = PATH_SEP + permalink;
      }
      permalink = permalink.replace(INDEX_RE, PATH_SEP);
      return permalink;
    }