Skip to content

Commit

Permalink
issue-#57 - Added some notes and reordered prop. declaration in 'type…
Browse files Browse the repository at this point in the history
…s' module.
  • Loading branch information
elycruz committed Feb 28, 2024
1 parent 7c2fecd commit 645f10a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 1 deletion.
3 changes: 3 additions & 0 deletions packages/fjl/src/list/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# list/

Contains methods for working with lists (strings, arrays, and/or array-likes (`all`, `foldl`, et al)), methods for working with iterables (`take`, `takeWhile` et al), and some generator methods (`repeat`, `replicate`, `cycle`, and `iterate` (et al)).
3 changes: 3 additions & 0 deletions packages/fjl/src/list/intersperse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ export const
return out;
},

/**
* Curried version of `intersperse`.
*/
$intersperse = <T = any, TS extends any[] = any[]>(between: T) =>
(xs: TS): any[] => intersperse(between, xs)

Expand Down
2 changes: 1 addition & 1 deletion packages/fjl/src/types/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ export interface Slice<T = any> extends Iterable<T> {

at(i: number): any; // @note Method not supported by older versions of typescript versions.
concat(...items: (Slice<T> | ConcatArray<any>)[]): this;
indexOf(x: any): number;
includes(x: any): boolean;
indexOf(x: any): number;
lastIndexOf(x: any): number;
slice(start: number, end?: number): this;
}
Expand Down
File renamed without changes.

0 comments on commit 645f10a

Please sign in to comment.