Skip to content

Commit 02748af

Browse files
improve module augmentation interface example
1 parent 991786f commit 02748af

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -312,11 +312,12 @@ declare module 'react-unity-renderer' {
312312
// Parameters<> helper type.
313313
info: [message: string];
314314

315-
// also possible:
316-
info: [string];
317315
// Note that all parameter names are just labels, so they are fully optional.
318316
// Though, they are displayed when autocompleting, so labels are quite helpful here.
319-
'some-event': [number, debug: string];
317+
'some-event': [number, string];
318+
319+
// If you want no parameters at all, just supply an empty tuple:
320+
'parameterless-event': [];
320321
}
321322
}
322323
```

0 commit comments

Comments
 (0)