🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@vyron/just-test

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vyron/just-test - npm Package Compare versions

Package was removed
Sorry, it seems this package was removed from the registry
Comparing version
1.1.2
to
1.1.4
+8
-1
package.json
{
"name": "@vyron/just-test",
"version": "1.1.2",
"version": "1.1.4",
"description": "",

@@ -13,2 +13,9 @@ "main": "index.js",

],
"files": [
"index.js",
"LICENSE",
"dist",
"package.json",
"README.md"
],
"author": "vyron",

@@ -15,0 +22,0 @@ "license": "MIT",

-7
{
"extends": "../../api-extractor.json",
"mainEntryPointFilePath": "./dist/packages/<unscopedPackageName>/src/index.d.ts",
"dtsRollup": {
"publicTrimmedFilePath": "./dist/<unscopedPackageName>.d.ts"
}
}
/*
* @Author: vyron
* @Date: 2022-01-10 17:38:09
* @LastEditTime: 2022-02-27 21:55:51
* @LastEditors: vyron
* @Description: 判断数据类型
* @FilePath: /v-utils/packages/type/src/index.ts
*/
// return value like "[object String]"
export const toTypeString = (value: unknown): string =>
Object.prototype.toString.call(value)
// return value line String | Boolean | Number | Array | Object | Function | RegExp | Date
export const toRawType = (value: unknown): string =>
toTypeString(value).slice(8, -1)
// 是否为 Array
export const isArray = Array.isArray
// 是否为 Map
export const isMap = (value: unknown): value is Map<any, any> =>
toRawType(value) === 'Map'
// 是否为 WeakMap
export const isWeakMap = (value: unknown): value is WeakMap<object, any> =>
toRawType(value) === 'WeakMap'
// 是否为 Set
export const isSet = (value: unknown): value is Set<any> =>
toRawType(value) === 'Set'
// 是否为 WeakSet
export const isWeakSet = (value: unknown): value is WeakSet<object> =>
toRawType(value) === 'WeakSet'
// 是否为 Object
export const isObject = (value: unknown): value is object =>
typeof value === 'object' && value !== null
// 是否为字符串
export const isString = (value: unknown): value is string =>
typeof value === 'string'