statuses/000755 001751 000166 0000000000 15020720275014402 5ustar00runner000000 000000 1502072027515020720275statuses/LICENSE000644 001751 000166 0000002165 15020720275015413 0ustar00runner000000 000000 1502072027515020720275 MIT License Copyright (c) Microsoft Corporation. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE statuses/README.md000644 001751 000166 0000003157 15020720275015674 0ustar00runner000000 000000 1502072066715020720275# Installation > `npm install --save @types/statuses` # Summary This package contains type definitions for statuses (https://github.com/jshttp/statuses). # Details Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/statuses. ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/statuses/index.d.ts) ````ts type NumericAscii = "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "0"; type NonNumericAscii = S extends `${NumericAscii}` ? never : any; type IsNumericString = S extends `${number}` ? any : never; type IsNonNumericString = S extends `${NonNumericAscii}${infer _}` ? any : never; export = status; declare const status: status; interface status { (code: number): string; (code: S): status.Result; codes: number[]; code: { [msg: string]: number | undefined }; empty: { [code: number]: boolean | undefined }; message: { [code: number]: string | undefined }; redirect: { [code: number]: boolean | undefined }; retry: { [code: number]: boolean | undefined }; } declare namespace status { type Result = S extends IsNumericString ? string : S extends IsNonNumericString ? number : string | number; } ```` ### Additional Details * Last updated: Sat, 07 Jun 2025 02:15:25 GMT * Dependencies: none # Credits These definitions were written by [Tanguy Krotoff](https://github.com/tkrotoff), [BendingBender](https://github.com/BendingBender), and [Sebastian Beltran](https://github.com/bjohansebas). statuses/index.d.ts000644 001751 000166 0000001662 15020720275016310 0ustar00runner000000 000000 1502072027515020720275type NumericAscii = "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "0"; type NonNumericAscii = S extends `${NumericAscii}` ? never : any; type IsNumericString = S extends `${number}` ? any : never; type IsNonNumericString = S extends `${NonNumericAscii}${infer _}` ? any : never; export = status; declare const status: status; interface status { (code: number): string; (code: S): status.Result; codes: number[]; code: { [msg: string]: number | undefined }; empty: { [code: number]: boolean | undefined }; message: { [code: number]: string | undefined }; redirect: { [code: number]: boolean | undefined }; retry: { [code: number]: boolean | undefined }; } declare namespace status { type Result = S extends IsNumericString ? string : S extends IsNonNumericString ? number : string | number; } statuses/package.json000644 001751 000166 0000002162 15020720275016676 0ustar00runner000000 000000 1502072066715020720275{ "name": "@types/statuses", "version": "2.0.6", "description": "TypeScript definitions for statuses", "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/statuses", "license": "MIT", "contributors": [ { "name": "Tanguy Krotoff", "githubUsername": "tkrotoff", "url": "https://github.com/tkrotoff" }, { "name": "BendingBender", "githubUsername": "BendingBender", "url": "https://github.com/BendingBender" }, { "name": "Sebastian Beltran", "githubUsername": "bjohansebas", "url": "https://github.com/bjohansebas" } ], "main": "", "types": "index.d.ts", "repository": { "type": "git", "url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git", "directory": "types/statuses" }, "scripts": {}, "dependencies": {}, "peerDependencies": {}, "typesPublisherContentHash": "afcdc0087e4ec2b0b72590176e614e7aaec60d6866b188121bb6e3f6eb2cdd55", "typeScriptVersion": "5.1" }