@wooksjs/event-http 0.4.25 → 0.4.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -8
- package/dist/index.cjs +360 -379
- package/dist/index.d.ts +123 -136
- package/dist/index.mjs +360 -379
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -11,10 +11,10 @@
|
|
|
11
11
|
|
|
12
12
|
As a part of `wooks` event processing framework, `@wooksjs/event-http` implements http events and provides composables that let you:
|
|
13
13
|
|
|
14
|
-
-
|
|
15
|
-
-
|
|
16
|
-
-
|
|
17
|
-
-
|
|
14
|
+
- parse urls search params
|
|
15
|
+
- parse cookies
|
|
16
|
+
- parse request body (json, url-encoded, form, ...)
|
|
17
|
+
- serve files
|
|
18
18
|
|
|
19
19
|
### The main ideas behind composable functions are:
|
|
20
20
|
|
|
@@ -25,9 +25,9 @@ As a part of `wooks` event processing framework, `@wooksjs/event-http` implement
|
|
|
25
25
|
|
|
26
26
|
### Official Wooks HTTP composables:
|
|
27
27
|
|
|
28
|
-
-
|
|
29
|
-
-
|
|
30
|
-
-
|
|
28
|
+
- [@wooksjs/http-body](https://github.com/wooksjs/wooksjs/tree/main/packages/http-body) - to parse body
|
|
29
|
+
- [@wooksjs/http-static](https://github.com/wooksjs/wooksjs/tree/main/packages/http-static) - to serve static files
|
|
30
|
+
- [@wooksjs/http-proxy](https://github.com/wooksjs/wooksjs/tree/main/packages/http-proxy) - to proxy requests
|
|
31
31
|
|
|
32
32
|
## Installation
|
|
33
33
|
|
|
@@ -47,7 +47,7 @@ app.on('GET', 'hello/:name', () => `Hello ${useRouteParams().get('name')}!`)
|
|
|
47
47
|
// app.get('hello/:name', () => `Hello ${ useRouteParams().get('name') }!`)
|
|
48
48
|
|
|
49
49
|
app.listen(3000, () => {
|
|
50
|
-
|
|
50
|
+
console.log('Wooks Server is up on port 3000')
|
|
51
51
|
})
|
|
52
52
|
```
|
|
53
53
|
|