0.3.18 • Published 1 year ago

@written/mkctx v0.3.18

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

Written Logo

@written/mkctx

Generate Appwrite Context Objects. Useful for testing & making non-appwrite-runner calls to appwrite functions.

See also: @written/httpcompat

Codeberg License

Installation

pnpm i @written/mkctx

Usage

The ctx constructor takes the same args as fetch(). Example:

import Ctx from '@written/mkctx';
const ctx = new Ctx('https://example.com/test', {
  method: 'POST',
});

// ...

(async () => {
  const response = await import('./someAppwriteFunc').default(ctx);
  // todo: handle response
})();

Obtaining Logs

You can use Ctx.getLogs(ctx)/Ctx.getErrors(ctx) to get the logs from the context object.

0.3.18

1 year ago

0.3.17

1 year ago

0.3.16

1 year ago

0.3.15

1 year ago

0.3.14

1 year ago

0.3.13

1 year ago

0.3.12

1 year ago

0.3.11

1 year ago

0.3.10

1 year ago

0.3.9

1 year ago

0.3.6

1 year ago

0.3.8

1 year ago

0.3.7

1 year ago

0.3.5

1 year ago

0.3.4

1 year ago

0.3.3

2 years ago

0.3.2

2 years ago

0.3.1

2 years ago

0.2.1

2 years ago

0.2.0

2 years ago

0.1.3

2 years ago

0.1.2

2 years ago

0.1.1

2 years ago