This commit is contained in:
Yamozha
2021-04-02 02:24:13 +03:00
parent c23950b545
commit 7256d79e2c
31493 changed files with 3036630 additions and 0 deletions

8
node_modules/nullthrows/LICENSE generated vendored Normal file
View File

@ -0,0 +1,8 @@
The MIT License (MIT)
Copyright (c) 2016 Andres Suarez
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.

7
node_modules/nullthrows/README.md generated vendored Normal file
View File

@ -0,0 +1,7 @@
# nullthrows
[![Build Status](https://travis-ci.org/zertosh/nullthrows.svg?branch=master)](https://travis-ci.org/zertosh/nullthrows)
A [flow](https://flowtype.org) typed utility that accepts `value` (e.g. `nullthrows(value)`) and throws if `value` is `null` or `undefined`, otherwise it returns `value`.
Also see [`invariant`](https://github.com/zertosh/invariant).

5
node_modules/nullthrows/nullthrows.d.ts generated vendored Normal file
View File

@ -0,0 +1,5 @@
/**
* Throws if value is null or undefined, otherwise returns value.
*/
export default function nullthrows<T>(value?: T | null, message?: string): T;

15
node_modules/nullthrows/nullthrows.js generated vendored Normal file
View File

@ -0,0 +1,15 @@
'use strict';
function nullthrows(x, message) {
if (x != null) {
return x;
}
var error = new Error(message !== undefined ? message : 'Got unexpected ' + x);
error.framesToPop = 1; // Skip nullthrows's own stack frame.
throw error;
}
module.exports = nullthrows;
module.exports.default = nullthrows;
Object.defineProperty(module.exports, '__esModule', {value: true});

3
node_modules/nullthrows/nullthrows.js.flow generated vendored Normal file
View File

@ -0,0 +1,3 @@
/* @flow strict */
declare module.exports: <T>(x: ?T, message?: string) => T;

38
node_modules/nullthrows/package.json generated vendored Normal file
View File

@ -0,0 +1,38 @@
{
"name": "nullthrows",
"version": "1.1.1",
"description": "flow typed nullthrows",
"keywords": [
"assert",
"flow",
"invariant",
"nullthrows"
],
"license": "MIT",
"author": "Andres Suarez <zertosh@gmail.com>",
"files": [
"nullthrows.d.ts",
"nullthrows.js",
"nullthrows.js.flow"
],
"main": "nullthrows.js",
"types": "nullthrows.d.ts",
"repository": "https://github.com/zertosh/nullthrows",
"scripts": {
"test": "jest"
},
"dependencies": {},
"devDependencies": {
"@babel/runtime-corejs2": "^7.0.0",
"flow-bin": "0.87.0",
"jest": "^23.5.0",
"typescript": "3.0.3"
},
"jest": {
"testEnvironment": "node",
"testPathIgnorePatterns": [
"/__fixtures__/"
],
"watchman": false
}
}