Skip to content

Commit

Permalink
Update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
tong committed Apr 18, 2024
1 parent c699f1f commit 7cfc97c
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,23 +1,24 @@
WTRI
====
Embeddable haxe/sys web server.
# WTRI

[![Build](https://github.com/tong/wtri/actions/workflows/build.yml/badge.svg)](https://github.com/tong/wtri/actions/workflows/build.yml)
Embeddable haxe/sys web server.

## Embed

```hx
new wtri.Server((req,res)-> {
Sys.println(req.path);
res.end('Hello!');
}).listen(8080);
```

See: [Main.hx](https://github.com/tong/wtri/blob/master/src/Main.hx)

---

## Example server

### Build

```sh
git clone https://github.com/tong/wtri.git
cd wtri/
Expand All @@ -33,6 +34,7 @@ make # HashlinkC
```

### Run

```sh
Usage: wtri [options]

Expand All @@ -44,3 +46,4 @@ Usage: wtri [options]
[--help] : Print this help
```

[![Build](https://github.com/tong/wtri/actions/workflows/build.yml/badge.svg)](https://github.com/tong/wtri/actions/workflows/build.yml)

0 comments on commit 7cfc97c

Please sign in to comment.