Skip to content

Error对象的类型定义是否有问题? #114

Open
@WhiteYin

Description

源码

const onError = proxy.onError;

error = {config: xhr.config, error: error, type: errorType};
if (onError) {
  onError(error, handler);
} else {
  handler.next(error);
}

类型定义

interface XhrError {
  config: XhrRequestConfig,
  type: XhrErrorType
}

onError?: (err: XhrError, handler: XhrErrorHandler) => void,

XhrError少个error属性的类型声明

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions