File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -5,31 +5,31 @@ export type CollectionConfig = {
5
5
/**
6
6
* - One or more glob patterns to match files to a collection
7
7
*/
8
- pattern : string | string [ ] ;
8
+ pattern ? : string | string [ ] | null ;
9
9
/**
10
10
* - A key to sort by (e.g. `date`,`title`, ..) or a custom sort function
11
11
*/
12
- sortBy : string | ( ( a : any , b : any ) => 0 | 1 | - 1 ) ;
12
+ sortBy ? : string | ( ( a : any , b : any ) => 0 | 1 | - 1 ) ;
13
13
/**
14
14
* - Limit the amount of items in a collection to `limit`
15
15
*/
16
- limit : number ;
16
+ limit ? : number ;
17
17
/**
18
18
* - Adds `next` and `previous` keys to file metadata of matched files
19
19
*/
20
- refer : boolean ;
20
+ refer ? : boolean ;
21
21
/**
22
22
* - Whether to invert the sorting function results (asc/descending)
23
23
*/
24
- reverse : boolean ;
24
+ reverse ? : boolean ;
25
25
/**
26
26
* - A function that gets a `Metalsmith.File` as first argument and returns `true` for every file to include in the collection
27
27
*/
28
- filterBy : Function ;
28
+ filterBy ? : Function ;
29
29
/**
30
30
* - An object with metadata to attach to the collection, or a `json`/`yaml`filepath string to load data from (relative to `Metalsmith.directory`)
31
31
*/
32
- metadata : any | string ;
32
+ metadata ? : any | string | null ;
33
33
} ;
34
34
/**
35
35
* Add `collections` of files to the global metadata as a sorted array.
You can’t perform that action at this time.
0 commit comments