https://github.com/adamjosefus/allo_responses
🦕 Prepared reponse classes for Deno.
https://github.com/adamjosefus/allo_responses
deno http response typescript utils
Last synced: 4 months ago
JSON representation
🦕 Prepared reponse classes for Deno.
- Host: GitHub
- URL: https://github.com/adamjosefus/allo_responses
- Owner: adamjosefus
- Created: 2022-02-20T09:05:42.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2022-03-06T21:32:08.000Z (almost 4 years ago)
- Last Synced: 2025-06-06T09:04:25.663Z (8 months ago)
- Topics: deno, http, response, typescript, utils
- Language: TypeScript
- Homepage:
- Size: 5.86 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Allo Reponses for Deno 🦕
Prepared reponse classes for Deno.
## Classes
### `TextResponse`
```ts
const r = new TextResponse('Lorem ipsum');
```
### `JsonResponse`
```ts
const r = new JsonResponse([{ foo: bar }]);
```
### `HtmlResponse`
```ts
const r = new HtmlResponse('
Hello World
');
```
### `FileResponse`
```ts
const r = new FileResponse('/path/to/file.ext');
```
```ts
const file: File = /*...*/;
const r = new FileResponse(file);
```
```ts
const file: Deno.FsFile = /*...*/;
const r = new FileResponse(file);
```
---
## Documentation 📖
Description of all classes and methods with **examples** will found in the [documentation](https://doc.deno.land/https://deno.land/x/allo_responses/mod.ts).
---
Check out other [ours packages 📦](https://deno.land/x?query=allo_)!