@hybridly/utils
Advanced tools
Comparing version 0.0.1-alpha.6 to 0.0.1-alpha.7
import makeDebugger from 'debug'; | ||
export { default as clone } from 'lodash.clonedeep'; | ||
@@ -35,2 +36,3 @@ declare type RequestData = Record<string, FormDataConvertible> | FormDataConvertible | FormData; | ||
declare function random(length?: number): string; | ||
/** Simple pattern matching util. */ | ||
declare function match<TValue extends string | number = string, TReturnValue = unknown>(value: TValue, lookup: Record<TValue | 'default', TReturnValue | ((...args: any[]) => TReturnValue)>, ...args: any[]): TReturnValue | Promise<TReturnValue>; | ||
@@ -40,3 +42,2 @@ declare function debounce<F extends (...params: any[]) => ReturnType<F>>(fn: F, delay: number): F; | ||
declare function when<T, D>(condition: any, data: T, _default?: D): T | D | undefined; | ||
declare function clone<T>(val: T): T; | ||
declare function merge<T>(x: Partial<T>, y: Partial<T>): T; | ||
@@ -56,2 +57,2 @@ | ||
export { FormDataConvertible, RequestData, clone, debounce, debug, hasFiles, match, merge, objectToFormData, random, showPageComponentErrorModal, showResponseErrorModal, value, when }; | ||
export { FormDataConvertible, RequestData, debounce, debug, hasFiles, match, merge, objectToFormData, random, showPageComponentErrorModal, showResponseErrorModal, value, when }; |
{ | ||
"name": "@hybridly/utils", | ||
"version": "0.0.1-alpha.6", | ||
"version": "0.0.1-alpha.7", | ||
"description": "A solution to develop server-driven, client-rendered applications", | ||
@@ -37,3 +37,4 @@ "keywords": [ | ||
"debug": "^4.3.4", | ||
"deepmerge": "^4.2.2" | ||
"deepmerge": "^4.2.2", | ||
"lodash.clonedeep": "^4.5.0" | ||
}, | ||
@@ -40,0 +41,0 @@ "scripts": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
23637
3
669
+ Addedlodash.clonedeep@^4.5.0
+ Addedlodash.clonedeep@4.5.0(transitive)