@nymphjs/server 1.0.0-beta.11 → 1.0.0-beta.12
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/CHANGELOG.md +6 -0
- package/dist/createServer.d.ts +5 -0
- package/dist/createServer.js +728 -0
- package/dist/createServer.js.map +1 -0
- package/dist/index.d.ts +5 -7
- package/dist/index.js +18 -790
- package/dist/index.js.map +1 -1
- package/dist/statusDescriptions.d.ts +3 -0
- package/dist/statusDescriptions.js +69 -0
- package/dist/statusDescriptions.js.map +1 -0
- package/package.json +6 -6
- package/src/createServer.ts +807 -0
- package/src/index.ts +5 -873
- package/src/statusDescriptions.ts +68 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* HTTP status code to status text map.
|
|
3
|
+
*/
|
|
4
|
+
export const statusDescriptions: { [k: number]: string } = {
|
|
5
|
+
100: 'Continue',
|
|
6
|
+
101: 'Switching Protocols',
|
|
7
|
+
102: 'Processing',
|
|
8
|
+
103: 'Early Hints',
|
|
9
|
+
200: 'OK',
|
|
10
|
+
201: 'Created',
|
|
11
|
+
202: 'Accepted',
|
|
12
|
+
203: 'Non-Authoritative Information',
|
|
13
|
+
204: 'No Content',
|
|
14
|
+
205: 'Reset Content',
|
|
15
|
+
206: 'Partial Content',
|
|
16
|
+
207: 'Multi-Status',
|
|
17
|
+
208: 'Already Reported',
|
|
18
|
+
226: 'IM Used',
|
|
19
|
+
300: 'Multiple Choices',
|
|
20
|
+
301: 'Moved Permanently',
|
|
21
|
+
302: 'Found',
|
|
22
|
+
303: 'See Other',
|
|
23
|
+
304: 'Not Modified',
|
|
24
|
+
305: 'Use Proxy',
|
|
25
|
+
306: 'Switch Proxy',
|
|
26
|
+
307: 'Temporary Redirect',
|
|
27
|
+
308: 'Permanent Redirect',
|
|
28
|
+
400: 'Bad Request',
|
|
29
|
+
401: 'Unauthorized',
|
|
30
|
+
402: 'Payment Required',
|
|
31
|
+
403: 'Forbidden',
|
|
32
|
+
404: 'Not Found',
|
|
33
|
+
405: 'Method Not Allowed',
|
|
34
|
+
406: 'Not Acceptable',
|
|
35
|
+
407: 'Proxy Authentication Required',
|
|
36
|
+
408: 'Request Timeout',
|
|
37
|
+
409: 'Conflict',
|
|
38
|
+
410: 'Gone',
|
|
39
|
+
411: 'Length Required',
|
|
40
|
+
412: 'Precondition Failed',
|
|
41
|
+
413: 'Payload Too Large',
|
|
42
|
+
414: 'URI Too Long',
|
|
43
|
+
415: 'Unsupported Media Type',
|
|
44
|
+
416: 'Range Not Satisfiable',
|
|
45
|
+
417: 'Expectation Failed',
|
|
46
|
+
418: "I'm a teapot",
|
|
47
|
+
421: 'Misdirected Request',
|
|
48
|
+
422: 'Unprocessable Entity',
|
|
49
|
+
423: 'Locked',
|
|
50
|
+
424: 'Failed Dependency',
|
|
51
|
+
425: 'Too Early',
|
|
52
|
+
426: 'Upgrade Required',
|
|
53
|
+
428: 'Precondition Required',
|
|
54
|
+
429: 'Too Many Requests',
|
|
55
|
+
431: 'Request Header Fields Too Large',
|
|
56
|
+
451: 'Unavailable For Legal Reasons',
|
|
57
|
+
500: 'Internal Server Error',
|
|
58
|
+
501: 'Not Implemented',
|
|
59
|
+
502: 'Bad Gateway',
|
|
60
|
+
503: 'Service Unavailable',
|
|
61
|
+
504: 'Gateway Timeout',
|
|
62
|
+
505: 'HTTP Version Not Supported',
|
|
63
|
+
506: 'Variant Also Negotiates',
|
|
64
|
+
507: 'Insufficient Storage',
|
|
65
|
+
508: 'Loop Detected',
|
|
66
|
+
510: 'Not Extended',
|
|
67
|
+
511: 'Network Authentication Required',
|
|
68
|
+
};
|