You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: example/README.md
+16-3Lines changed: 16 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,7 +21,6 @@ bun run example:basic
21
21
```
22
22
23
23
from the root of this repository.
24
-
25
24
## Server Example
26
25
27
26
The server example demonstrates how you can use [@sebastianwessel/quickjs](https://github.com/sebastianwessel/quickjs) inside a web server. In this example, we run a web server that spawns workers on request using the [poolifier-web-worker](https://github.com/poolifier/poolifier-web-worker) package. Each worker runs its own QuickJS sandbox and executes the given code.
@@ -34,12 +33,26 @@ bun run example:server
34
33
35
34
from the root of this repository. Once the server has started, open your browser and go to [http://localhost:3000/](http://localhost:3000/). You will see a simple OpenAPI (Swagger) UI.
36
35
36
+
If port 3000 is already in use, choose another port:
37
+
38
+
```sh
39
+
PORT=3910 bun run example:server
40
+
```
41
+
37
42
## Run-Tests Example
38
43
39
-
In the *run-tests* example, the usage of the included test runner is shown. You can test it out by running:
44
+
In the *run-tests* example, the usage of the included test runner is shown.
45
+
46
+
Before running the tests, build the test runner library:
0 commit comments