Skip to content

@opencraft/providence


Interface: NetCallOptions\<T>

Defined in: types/NetCallOptions.ts:9

NetCallOptions are the arguments for the netCall function.

Type Parameters

T

T

The type of the data being sent as JSON (or otherwise structured) data.

Properties

data?

optional data?: T

Defined in: types/NetCallOptions.ts:14

JSON/structured data to send to the endpoint. May be undefined if this is a get request.


method?

optional method?: Method

Defined in: types/NetCallOptions.ts:12

HTTP Verb, like get, post, patch, put, or delete.


params?

optional params?: QueryParams

Defined in: types/NetCallOptions.ts:16

Query parameters. Will construct a query string based on stringifying the contents of this object.


signal

signal: AbortSignal

Defined in: types/NetCallOptions.ts:18

AbortSignal, now standard in all browsers that matter. Used to abort a call from outside.


url

url: string

Defined in: types/NetCallOptions.ts:10