mirror of
https://github.com/archtechx/laravel-tips.git
synced 2025-12-12 13:24:03 +00:00
658 B
658 B
| title | tweet_id | thread_slug | author_username | images | created_at | slug | |
|---|---|---|---|---|---|---|---|
| Improve the DX of your commands by making arguments optional and prompting the user when they're empty | 1515057387027140609 | weekly-thread-2022-15 | mmartin_joo |
|
2022-04-15T20:00:04+00:00 | improve-the-dx-of-your-commands-by-making-arguments-optional-and-prompting-the-user-when-theyre-empty |
💡 Just a quick tip: define every argument of commands as optional and ask for input if they are missing.
This way, you don’t need to think about the arguments when running a command.
Just run it, and it will ask everything: