@ztimson/utils 0.23.19 → 0.23.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +24 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +24 -8
- package/dist/index.mjs.map +1 -1
- package/dist/string.d.ts +16 -2
- package/package.json +1 -1
package/dist/string.d.ts
CHANGED
|
@@ -15,9 +15,9 @@ export declare const SYMBOL_LIST = "~`!@#$%^&*()_-+={[}]|\\:;\"'<,>.?/";
|
|
|
15
15
|
*/
|
|
16
16
|
export declare const CHAR_LIST: string;
|
|
17
17
|
/**
|
|
18
|
-
* Converts text to
|
|
18
|
+
* Converts text to camelCase
|
|
19
19
|
*/
|
|
20
|
-
export declare function camelCase(
|
|
20
|
+
export declare function camelCase(str?: string): string;
|
|
21
21
|
/**
|
|
22
22
|
* Convert number of bytes into a human-readable size
|
|
23
23
|
*
|
|
@@ -49,6 +49,10 @@ export declare function formatPhoneNumber(number: string): string;
|
|
|
49
49
|
* @deprecated use `strSplice()`
|
|
50
50
|
*/
|
|
51
51
|
export declare function insertAt(target: string, str: string, index: number): String;
|
|
52
|
+
/**
|
|
53
|
+
* Converts text to kebab-case
|
|
54
|
+
*/
|
|
55
|
+
export declare function kebabCase(str: string): string;
|
|
52
56
|
/**
|
|
53
57
|
* Add padding to string
|
|
54
58
|
*
|
|
@@ -67,6 +71,12 @@ export declare function insertAt(target: string, str: string, index: number): St
|
|
|
67
71
|
* @deprecated Please use `String.padStart` & `String.padEnd`
|
|
68
72
|
*/
|
|
69
73
|
export declare function pad(text: any, length: number, char?: string, start?: boolean): any;
|
|
74
|
+
/**
|
|
75
|
+
* Convert text to PascalCase
|
|
76
|
+
* @param {string} str
|
|
77
|
+
* @return {string}
|
|
78
|
+
*/
|
|
79
|
+
export declare function pascalCase(str?: string): string;
|
|
70
80
|
/**
|
|
71
81
|
* Generate a random hexadecimal value
|
|
72
82
|
*
|
|
@@ -104,6 +114,10 @@ export declare function randomString(length: number, pool?: string): string;
|
|
|
104
114
|
* @return {string} generated string
|
|
105
115
|
*/
|
|
106
116
|
export declare function randomStringBuilder(length: number, letters?: boolean, numbers?: boolean, symbols?: boolean): string;
|
|
117
|
+
/**
|
|
118
|
+
* Converts text to snake_case
|
|
119
|
+
*/
|
|
120
|
+
export declare function snakeCase(str?: string): string;
|
|
107
121
|
/**
|
|
108
122
|
* Splice a string together (Similar to Array.splice)
|
|
109
123
|
*
|