Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/xhr/globals.d.ts>XMLHttpRequest

An XMLHttpRequest polyfill for Deno CLI and Deploy 🦕
Very Popular
Latest
variable XMLHttpRequest
import { XMLHttpRequest } from "https://deno.land/x/xhr@0.4.3/globals.d.ts";

XMLHttpRequest (XHR) objects are used to interact with servers. You can retrieve data from a URL without having to do a full page refresh. This enables a Web page to update just part of a page without disrupting what the user is doing.

Despite its name, XMLHttpRequest can be used to retrieve any type of data, not just XML.

type

{ prototype: XMLHttpRequest; readonly DONE: number; readonly HEADERS_RECEIVED: number; readonly LOADING: number; readonly OPENED: number; readonly UNSENT: number; new (): XMLHttpRequest; }