summaryrefslogtreecommitdiff
path: root/node_modules/arrify
diff options
context:
space:
mode:
authorlittleblack111 <littleblack11111@gmail.com>2026-05-18 23:10:59 +0800
committerlittleblack111 <littleblack11111@gmail.com>2026-05-18 23:41:44 +0800
commitfc87c009806dcc98867f6b58efe29b042aa01dee (patch)
tree8f59b3f4a5b66e9dfef2d40c8d318e258a521228 /node_modules/arrify
parent3336b2356ee6152d9c6ae59bd9b87ccbc0958407 (diff)
node: updatemain
Diffstat (limited to 'node_modules/arrify')
-rw-r--r--node_modules/arrify/index.d.ts38
-rw-r--r--node_modules/arrify/index.js23
-rw-r--r--node_modules/arrify/license9
-rw-r--r--node_modules/arrify/package.json35
-rw-r--r--node_modules/arrify/readme.md39
5 files changed, 0 insertions, 144 deletions
diff --git a/node_modules/arrify/index.d.ts b/node_modules/arrify/index.d.ts
deleted file mode 100644
index bfd0cf5e..00000000
--- a/node_modules/arrify/index.d.ts
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
-Convert a value to an array.
-
-_Supplying `null` or `undefined` results in an empty array._
-
-@example
-```
-import arrify = require('arrify');
-
-arrify('🦄');
-//=> ['🦄']
-
-arrify(['🦄']);
-//=> ['🦄']
-
-arrify(new Set(['🦄']));
-//=> ['🦄']
-
-arrify(null);
-//=> []
-
-arrify(undefined);
-//=> []
-```
-*/
-declare function arrify<ValueType>(
- value: ValueType
-): ValueType extends (null | undefined)
- ? []
- : ValueType extends string
- ? [string]
- : ValueType extends ReadonlyArray<unknown> // TODO: Use 'readonly unknown[]' in the next major version
- ? ValueType
- : ValueType extends Iterable<infer T>
- ? T[]
- : [ValueType];
-
-export = arrify;
diff --git a/node_modules/arrify/index.js b/node_modules/arrify/index.js
deleted file mode 100644
index 49a5c9ad..00000000
--- a/node_modules/arrify/index.js
+++ /dev/null
@@ -1,23 +0,0 @@
-'use strict';
-
-const arrify = value => {
- if (value === null || value === undefined) {
- return [];
- }
-
- if (Array.isArray(value)) {
- return value;
- }
-
- if (typeof value === 'string') {
- return [value];
- }
-
- if (typeof value[Symbol.iterator] === 'function') {
- return [...value];
- }
-
- return [value];
-};
-
-module.exports = arrify;
diff --git a/node_modules/arrify/license b/node_modules/arrify/license
deleted file mode 100644
index e7af2f77..00000000
--- a/node_modules/arrify/license
+++ /dev/null
@@ -1,9 +0,0 @@
-MIT License
-
-Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
-
-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.
diff --git a/node_modules/arrify/package.json b/node_modules/arrify/package.json
deleted file mode 100644
index 07578884..00000000
--- a/node_modules/arrify/package.json
+++ /dev/null
@@ -1,35 +0,0 @@
-{
- "name": "arrify",
- "version": "2.0.1",
- "description": "Convert a value to an array",
- "license": "MIT",
- "repository": "sindresorhus/arrify",
- "author": {
- "name": "Sindre Sorhus",
- "email": "sindresorhus@gmail.com",
- "url": "sindresorhus.com"
- },
- "engines": {
- "node": ">=8"
- },
- "scripts": {
- "test": "xo && ava && tsd"
- },
- "files": [
- "index.js",
- "index.d.ts"
- ],
- "keywords": [
- "array",
- "arrify",
- "arrayify",
- "convert",
- "value",
- "ensure"
- ],
- "devDependencies": {
- "ava": "^1.4.1",
- "tsd": "^0.7.2",
- "xo": "^0.24.0"
- }
-}
diff --git a/node_modules/arrify/readme.md b/node_modules/arrify/readme.md
deleted file mode 100644
index b3dfc837..00000000
--- a/node_modules/arrify/readme.md
+++ /dev/null
@@ -1,39 +0,0 @@
-# arrify [![Build Status](https://travis-ci.org/sindresorhus/arrify.svg?branch=master)](https://travis-ci.org/sindresorhus/arrify)
-
-> Convert a value to an array
-
-
-## Install
-
-```
-$ npm install arrify
-```
-
-
-## Usage
-
-```js
-const arrify = require('arrify');
-
-arrify('🦄');
-//=> ['🦄']
-
-arrify(['🦄']);
-//=> ['🦄']
-
-arrify(new Set(['🦄']));
-//=> ['🦄']
-
-arrify(null);
-//=> []
-
-arrify(undefined);
-//=> []
-```
-
-*Supplying `null` or `undefined` results in an empty array.*
-
-
-## License
-
-MIT © [Sindre Sorhus](https://sindresorhus.com)