Skip to content

Commit f395613

Browse files
committed
Use lambda style function type declarations
1 parent d2a3ec2 commit f395613

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -53,22 +53,22 @@ Properties you can pass to the console element
5353

5454
| Prop | Type | Description
5555
| ---- | ---- | ----
56-
| autofocus? | bool | Autofocus the console on component mount.
57-
| cancel? | function(): any | Function that should stop execution of the current command and call `this.return()`.
58-
| complete? | function(words: string[], cursor: number, prompt: string): string[] | Return a list of possible completions given a list of (`words`), index of the word containing the cursor (`cursor`) , and the full prompt text (`prompt`).
59-
| continue? | function(prompt: string): bool | Return a boolean indicating whether to continue asking for user input on a newline given the current prompt text (`prompt`).
60-
| handler | function(command: string): any | Handle a command (`command`), logging data with `this.log()` or `this.logX()`, and calling `this.return()` when finished.
61-
| promptLabel? | string \| function(): string | String displayed to prompt user for input.
62-
| welcomeMessage? | string | Initial message displayed after mount.
56+
| autofocus? | bool | Autofocus the console on component mount.
57+
| cancel? | ()=>any | Function that should stop execution of the current command and call `this.return()`.
58+
| complete? | (words: string[], cursor: number, prompt: string)=>string[] | Return a list of possible completions given a list of (`words`), index of the word containing the cursor (`cursor`) , and the full prompt text (`prompt`).
59+
| continue? | (prompt: string)=>bool | Return a boolean indicating whether to continue asking for user input on a newline given the current prompt text (`prompt`).
60+
| handler | (command: string)=>any | Handle a command (`command`), logging data with `this.log()` or `this.logX()`, and calling `this.return()` when finished.
61+
| promptLabel? | string \| ()=>string | String displayed to prompt user for input.
62+
| welcomeMessage? | string | Initial message displayed after mount.
6363

6464

6565
## Public members
6666

6767
| Member | Type | Description
6868
| ---- | ---- | ----
69-
| log | function(...messages: any): void | Log messages to the console. If string, print the value, otherwise, print the JSON value of the message.
70-
| logX | function(type: string, ...messages: any): void | Log messages of a particular type to the console. The messages will be given the class `react-console-message-{type}`.
71-
| return | function(): void | Signal the current command has finished and a new prompt should be displayed.
69+
| log | (...messages: any)=>void | Log messages to the console. If string, print the value, otherwise, print the JSON value of the message.
70+
| logX | (type: string, ...messages: any)=>void | Log messages of a particular type to the console. The messages will be given the class `react-console-message-{type}`.
71+
| return | ()=>void | Signal the current command has finished and a new prompt should be displayed.
7272

7373

7474
## Awknoledgements

0 commit comments

Comments
 (0)