code: function snakeCase (str) {
    return str
      .replace(/([a-z])([A-Z])/g, match => match[0] + '_' + match[1])
      .replace(invalidChars, '_')
      .toLowerCase()
  }
docs: Convert text to snake_case
  @param {string} str Text to be converted
  @return {string}