PythonMonkey: python/pythonmonkey/builtin_modules/XMLHttpRequest.js File Reference

Classes

class  ProgressEvent
 
class  XMLHttpRequestEventTarget
 
class  XMLHttpRequestUpload
 
class  XMLHttpRequest
 

Functions

function trunc (what, maxlen, coerce)
 
 if (!globalThis.XMLHttpRequestEventTarget) globalThis.XMLHttpRequestEventTarget
 

Variables

use strict
 
 const { EventTarget, Event } = require('event-target')
 
const debug = globalThis.python.eval('__import__("pythonmonkey").bootstrap.require')('debug')
 
const FORBIDDEN_REQUEST_METHODS
 
exports XMLHttpRequestEventTarget = XMLHttpRequestEventTarget
 
exports XMLHttpRequestUpload = XMLHttpRequestUpload
 
exports XMLHttpRequest = XMLHttpRequest
 
exports ProgressEvent = ProgressEvent
 

Implement the XMLHttpRequest (XHR) API

Date
August 2023
Copyright
Copyright (c) 2023 Distributive Corp.

◆ if()

if ( !globalThis.  XMLHttpRequestEventTarget)

◆ trunc()

function trunc (   what,
  maxlen,
  coerce 
)

Truncate a string-like thing for display purposes, returning a string.

Parameters
{any}what The thing to truncate; must have a slice method and index property. Works with string, array, typedarray, etc.
{number}maxlen The maximum length for truncation
{boolean=}coerce Not false = coerce to printable character codes
Returns
{string}

◆ const

◆ debug

◆ FORBIDDEN_REQUEST_METHODS

const FORBIDDEN_REQUEST_METHODS

Initial value:

= [

'TRACE',

'TRACK',

'CONNECT'

]

◆ ProgressEvent

◆ strict

◆ XMLHttpRequestEventTarget

◆ XMLHttpRequestUpload