parseXML = xmlString => {
  const parser = new window.DOMParser()
  const xml = parser.parseFromString(xmlString, 'text/xml')
  const formData = []

  if (xml) {
    const fields = xml.getElementsByTagName('field')
    for (let i = 0; i < fields.length; i++) {
      const fieldData = xmlParseAttrs(fields[i])
      const options = fields[i].getElementsByTagName('option')
      const userData = fields[i].getElementsByTagName('userData')

      if (options && options.length) {
        fieldData.values = xmlParseOptions(options)
      }

      if (userData && userData.length) {
        fieldData.userData = xmlParseUserData(userData)
      }

      formData.push(fieldData)
    }
  }

  return formData
}
Parse XML formData
@param  {string} xmlString
@return {Array}            formData array