Skip to content

Commit

Permalink
chore(@clack/prompts): update readme (#162)
Browse files Browse the repository at this point in the history
  • Loading branch information
natemoo-re authored Dec 14, 2024
2 parents dcc5827 + d20891b commit 564e717
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/prompts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ The `isCancel` function is a guard that detects when a user cancels a question w
```js
import { isCancel, cancel, text } from '@clack/prompts';

const value = await text(/* TODO */);
const value = await text({
message: 'What is the meaning of life?',
});

if (isCancel(value)) {
cancel('Operation cancelled.');
Expand Down

0 comments on commit 564e717

Please sign in to comment.