Skip to content

Commit d3e8eda

Browse files
committed
explain the noop function
Signed-off-by: Kipras Melnikovas <kipras@kipras.org>
1 parent 9c5d1e2 commit d3e8eda

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

util/noop.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/**
2+
* a simple function that does nothing (no-operation),
3+
* used to prevent compiler errors for unused code.
4+
* especially useful if you're experimenting temporarily.
5+
*/
16
export function noop(..._xs: any[]): void {
27
//
38
}

0 commit comments

Comments
 (0)