Options
All
  • Public
  • Public/Protected
  • All
Menu
export
interface

CancelToken

description

在外部执行 cancel 函数时,能够执行 xhr.abort 方法取消请求 这个时候就用 promise 实现,在 then 函数中实现该需求 实例类型接口定义

export
class

CancelToken

Hierarchy

  • CancelToken

Index

Constructors

Properties

Methods

Constructors

constructor

Properties

promise

promise: Promise<Cancel>

Optional reason

reason: Cancel

Methods

throwRequested

  • throwRequested(): void

Static source

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method

Generated using TypeDoc