aurelia / aurelia/http-client

Canceling requests with TypeScript

Open
#120 19 comments 0 reactions 0 assignees View on GitHub
external
Dominant language
JavaScript
Stars
60
Forks
57
PR merge metrics
No merged PRs in 30d

Description

Since the `cancel/abort` function is added runtime to the `Promise` returned by `.send()` in [`http-client.js`](https://github.com/aurelia/http-client/blob/master/src/http-client.js#L107), the TypeScript compiler doesn't know about its existence.

Contributor guide

Open the contributing guide

Research direction

Start at src/http-client.js around line 107 and inspect how the runtime cancel/abort function is added to the Promise returned by .send(). Check the TypeScript-facing definition or compiler path for that return value; done when TypeScript recognizes the available cancellation function without an error.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
api
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.