File tree 4 files changed +38
-42
lines changed
4 files changed +38
-42
lines changed Original file line number Diff line number Diff line change 1
1
language : node_js
2
2
node_js :
3
+ - ' 12'
3
4
- ' 10'
4
5
- ' 8'
Original file line number Diff line number Diff line change @@ -83,42 +83,35 @@ declare namespace slugify {
83
83
}
84
84
}
85
85
86
- declare const slugify : {
87
- /**
88
- Slugify a string.
89
-
90
- @param input - The string to slugify.
91
-
92
- @example
93
- ```
94
- import slugify = require('@sindresorhus/slugify');
95
-
96
- slugify('I ♥ Dogs');
97
- //=> 'i-love-dogs'
98
-
99
- slugify(' Déjà Vu! ');
100
- //=> 'deja-vu'
101
-
102
- slugify('fooBar 123 $#%');
103
- //=> 'foo-bar-123'
104
-
105
- slugify('I ♥ 🦄 & 🐶', {
106
- customReplacements: [
107
- ['🐶', 'dog']
108
- ]
109
- });
110
- //=> 'i-love-unicorn-and-dog'
111
- ```
112
- */
113
- ( input : string , options ?: slugify . Options ) : string ;
114
-
115
- // TODO: Remove this for the next major release, refactor the whole definition to:
116
- // declare function slugify(
117
- // input: string,
118
- // options?: slugify.Options
119
- // ): string;
120
- // export = slugify;
121
- default : typeof slugify ;
122
- } ;
86
+ /**
87
+ Slugify a string.
88
+
89
+ @param string - String to slugify.
90
+
91
+ @example
92
+ ```
93
+ import slugify = require('@sindresorhus/slugify');
94
+
95
+ slugify('I ♥ Dogs');
96
+ //=> 'i-love-dogs'
97
+
98
+ slugify(' Déjà Vu! ');
99
+ //=> 'deja-vu'
100
+
101
+ slugify('fooBar 123 $#%');
102
+ //=> 'foo-bar-123'
103
+
104
+ slugify('I ♥ 🦄 & 🐶', {
105
+ customReplacements: [
106
+ ['🐶', 'dog']
107
+ ]
108
+ });
109
+ //=> 'i-love-unicorn-and-dog'
110
+ ```
111
+ */
112
+ declare function slugify (
113
+ string : string ,
114
+ options ?: slugify . Options
115
+ ) : string ;
123
116
124
117
export = slugify ;
Original file line number Diff line number Diff line change 41
41
" id"
42
42
],
43
43
"dependencies" : {
44
- "escape-string-regexp" : " ^1 .0.5 " ,
44
+ "escape-string-regexp" : " ^2 .0.0 " ,
45
45
"lodash.deburr" : " ^4.1.0"
46
46
},
47
47
"devDependencies" : {
48
48
"ava" : " ^1.4.1" ,
49
- "tsd" : " ^0.7.2 " ,
49
+ "tsd" : " ^0.7.3 " ,
50
50
"xo" : " ^0.24.0"
51
51
}
52
52
}
Original file line number Diff line number Diff line change @@ -38,15 +38,17 @@ slugify('I ♥ 🦄 & 🐶', {
38
38
39
39
## API
40
40
41
- ### slugify(input , [ options] )
41
+ ### slugify(string , [ options] )
42
42
43
- #### input
43
+ #### string
44
44
45
45
Type: ` string `
46
46
47
+ String to slugify.
48
+
47
49
#### options
48
50
49
- Type: ` Object `
51
+ Type: ` object `
50
52
51
53
##### separator
52
54
You can’t perform that action at this time.
0 commit comments