Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@antfu/utils

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@antfu/utils - npm Package Compare versions

Comparing version 0.1.4 to 0.1.5

10

dist/index.d.ts

@@ -161,4 +161,12 @@ /**

* Replace backslash to slash
*
* @category String
*/
declare function slash(str: string): string;
/**
* Ensure prefix of a string
*
* @category String
*/
declare function ensurePrefix(prefix: string, str: string): string;

@@ -264,2 +272,2 @@ declare const timestamp: () => number;

export { ArgumentsType, Arrayable, Awaitable, DeepMerge, ElementOf, Fn, MergeInsertions, Nullable, SingletonPromiseReturn, UnionToIntersection, assert, at, batchInvoke, clamp, clampArrayRange, createSingletonPromise, deepMerge, flattenArrayable, invoke, isBoolean, isBrowser, isDef, isFunction, isKeyOf, isNumber, isObject, isString, isTruthy, isWindow, last, mergeArrayable, move, noNull, noop, notNullish, notUndefined, objectEntries, objectKeys, objectMap, objectPick, partition, range, remove, slash, sleep, sum, timestamp, toArray, toString, uniq };
export { ArgumentsType, Arrayable, Awaitable, DeepMerge, ElementOf, Fn, MergeInsertions, Nullable, SingletonPromiseReturn, UnionToIntersection, assert, at, batchInvoke, clamp, clampArrayRange, createSingletonPromise, deepMerge, ensurePrefix, flattenArrayable, invoke, isBoolean, isBrowser, isDef, isFunction, isKeyOf, isNumber, isObject, isString, isTruthy, isWindow, last, mergeArrayable, move, noNull, noop, notNullish, notUndefined, objectEntries, objectKeys, objectMap, objectPick, partition, range, remove, slash, sleep, sum, timestamp, toArray, toString, uniq };

10

dist/index.js

@@ -110,6 +110,11 @@ "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/math.ts

// src/path.ts
// src/string.ts
function slash(str) {
return str.replace(/\\/g, "/");
}
function ensurePrefix(prefix, str) {
if (!str.startsWith(prefix))
return prefix + str;
return str;
}

@@ -235,2 +240,3 @@ // src/time.ts

exports.assert = assert; exports.at = at; exports.batchInvoke = batchInvoke; exports.clamp = clamp; exports.clampArrayRange = clampArrayRange; exports.createSingletonPromise = createSingletonPromise; exports.deepMerge = deepMerge; exports.flattenArrayable = flattenArrayable; exports.invoke = invoke; exports.isBoolean = isBoolean; exports.isBrowser = isBrowser; exports.isDef = isDef; exports.isFunction = isFunction; exports.isKeyOf = isKeyOf; exports.isNumber = isNumber; exports.isObject = isObject; exports.isString = isString; exports.isTruthy = isTruthy; exports.isWindow = isWindow; exports.last = last; exports.mergeArrayable = mergeArrayable; exports.move = move; exports.noNull = noNull; exports.noop = noop; exports.notNullish = notNullish; exports.notUndefined = notUndefined; exports.objectEntries = objectEntries; exports.objectKeys = objectKeys; exports.objectMap = objectMap; exports.objectPick = objectPick; exports.partition = partition; exports.range = range; exports.remove = remove; exports.slash = slash; exports.sleep = sleep; exports.sum = sum; exports.timestamp = timestamp; exports.toArray = toArray; exports.toString = toString2; exports.uniq = uniq;
exports.assert = assert; exports.at = at; exports.batchInvoke = batchInvoke; exports.clamp = clamp; exports.clampArrayRange = clampArrayRange; exports.createSingletonPromise = createSingletonPromise; exports.deepMerge = deepMerge; exports.ensurePrefix = ensurePrefix; exports.flattenArrayable = flattenArrayable; exports.invoke = invoke; exports.isBoolean = isBoolean; exports.isBrowser = isBrowser; exports.isDef = isDef; exports.isFunction = isFunction; exports.isKeyOf = isKeyOf; exports.isNumber = isNumber; exports.isObject = isObject; exports.isString = isString; exports.isTruthy = isTruthy; exports.isWindow = isWindow; exports.last = last; exports.mergeArrayable = mergeArrayable; exports.move = move; exports.noNull = noNull; exports.noop = noop; exports.notNullish = notNullish; exports.notUndefined = notUndefined; exports.objectEntries = objectEntries; exports.objectKeys = objectKeys; exports.objectMap = objectMap; exports.objectPick = objectPick; exports.partition = partition; exports.range = range; exports.remove = remove; exports.slash = slash; exports.sleep = sleep; exports.sum = sum; exports.timestamp = timestamp; exports.toArray = toArray; exports.toString = toString2; exports.uniq = uniq;
{
"name": "@antfu/utils",
"version": "0.1.4",
"version": "0.1.5",
"description": "Opinionated collection of common JavaScript / TypeScript utils by @antfu",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

# @antfu/utils
[![NPM version](https://img.shields.io/npm/v/@antfu/utils?color=a1b858&label=)](https://www.npmjs.com/package/@antfu/utils)
[![Docs](https://www.paka.dev/badges/v0/cute.svg)](https://www.paka.dev/npm/@antfu/utils)

@@ -5,0 +6,0 @@ Opinionated collection of common JavaScript / TypeScript utils by [@antfu](https://github.com/antfu).

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc