@poppinss/utils 6.0.0-0 → 6.0.0-1
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/build/src/json/main.d.ts +2 -2
- package/build/src/json/main.js +2 -1
- package/build/src/string/main.d.ts +4 -4
- package/build/src/string/main.js +4 -3
- package/build/src/string/{to_sentence.d.ts → sentence.d.ts} +1 -1
- package/build/src/string/{to_sentence.js → sentence.js} +1 -1
- package/package.json +1 -1
package/build/src/json/main.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { safeParse } from './safe_parse.js';
|
|
2
2
|
import { safeStringify } from './safe_stringify.js';
|
|
3
|
-
declare const
|
|
3
|
+
declare const json: {
|
|
4
4
|
safeParse: typeof safeParse;
|
|
5
5
|
safeStringify: typeof safeStringify;
|
|
6
6
|
};
|
|
7
|
-
export default
|
|
7
|
+
export default json;
|
package/build/src/json/main.js
CHANGED
|
@@ -2,12 +2,12 @@ import { random } from './random.js';
|
|
|
2
2
|
import { excerpt } from './excerpt.js';
|
|
3
3
|
import { ordinal } from './ordinal.js';
|
|
4
4
|
import { truncate } from './truncate.js';
|
|
5
|
-
import {
|
|
5
|
+
import { sentence } from './sentence.js';
|
|
6
6
|
import { interpolate } from './interpolate.js';
|
|
7
7
|
import { pluralize } from './pluralize.js';
|
|
8
8
|
import { noCase, dotCase, dashCase, camelCase, snakeCase, titleCase, pascalCase, capitalCase, sentenceCase } from './change_case.js';
|
|
9
9
|
declare function condenseWhitespace(value: string): string;
|
|
10
|
-
declare const
|
|
10
|
+
declare const string: {
|
|
11
11
|
excerpt: typeof excerpt;
|
|
12
12
|
truncate: typeof truncate;
|
|
13
13
|
slug: typeof import("slugify").default;
|
|
@@ -27,7 +27,7 @@ declare const _default: {
|
|
|
27
27
|
snakeCase: typeof snakeCase;
|
|
28
28
|
titleCase: typeof titleCase;
|
|
29
29
|
random: typeof random;
|
|
30
|
-
|
|
30
|
+
sentence: typeof sentence;
|
|
31
31
|
condenseWhitespace: typeof condenseWhitespace;
|
|
32
32
|
seconds: {
|
|
33
33
|
format(seconds: number, long?: boolean | undefined): string;
|
|
@@ -43,4 +43,4 @@ declare const _default: {
|
|
|
43
43
|
};
|
|
44
44
|
ordinal: typeof ordinal;
|
|
45
45
|
};
|
|
46
|
-
export default
|
|
46
|
+
export default string;
|
package/build/src/string/main.js
CHANGED
|
@@ -6,14 +6,14 @@ import { excerpt } from './excerpt.js';
|
|
|
6
6
|
import { ordinal } from './ordinal.js';
|
|
7
7
|
import { truncate } from './truncate.js';
|
|
8
8
|
import milliseconds from './milliseconds.js';
|
|
9
|
-
import {
|
|
9
|
+
import { sentence } from './sentence.js';
|
|
10
10
|
import { interpolate } from './interpolate.js';
|
|
11
11
|
import { plural, pluralize, singular, isPlural, isSingular } from './pluralize.js';
|
|
12
12
|
import { noCase, dotCase, dashCase, camelCase, snakeCase, titleCase, pascalCase, capitalCase, sentenceCase, } from './change_case.js';
|
|
13
13
|
function condenseWhitespace(value) {
|
|
14
14
|
return value.trim().replace(/\s{2,}/g, ' ');
|
|
15
15
|
}
|
|
16
|
-
|
|
16
|
+
const string = {
|
|
17
17
|
excerpt,
|
|
18
18
|
truncate,
|
|
19
19
|
slug,
|
|
@@ -33,10 +33,11 @@ export default {
|
|
|
33
33
|
snakeCase,
|
|
34
34
|
titleCase,
|
|
35
35
|
random,
|
|
36
|
-
|
|
36
|
+
sentence,
|
|
37
37
|
condenseWhitespace,
|
|
38
38
|
seconds,
|
|
39
39
|
milliseconds,
|
|
40
40
|
bytes,
|
|
41
41
|
ordinal,
|
|
42
42
|
};
|
|
43
|
+
export default string;
|