code: function request (url) {
    return new Promise((resolve, reject) => {
      const xhr = new XMLHttpRequest()
  
      xhr.open('GET', url)
      xhr.setRequestHeader('Content-Type', 'application/json')
      xhr.addEventListener('load', _ => {
        try {
          const response = JSON.parse(xhr.response)
  
          resolve(response)
        } catch (e) {
          reject(e)
        };
      })
  
      xhr.send(null)
    })
  }
docs: /*eslint no-undef: 0