Download the PHP package vangelis/todoordie without Composer
On this page you can find all versions of the php package vangelis/todoordie. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download vangelis/todoordie
More information about vangelis/todoordie
Files in vangelis/todoordie
Package todoordie
Short Description Write TODOs in code that ensure you actually do them
License MIT
Homepage https://github.com/vangelis/todoordie
Informations about the package todoordie
Write TODOs in code that ensure you actually do them
Keep your projects clean
To understand why you would ever call a function to write a comment, read on.
If you have some code you know you'll need to change later, don't just leave a comment for later that you'll never read, ever again.
For all the following cases, forgetting a TODO is NOT GOOD:
- remove some code when the dependency support expires,
- remove a feature flag,
- update some code related to another project,
- update a dependency when another refactoring is done,
- ...
This can lead to nasty issues so make your TODOs speak up when they need to with this module ;)
You can now replace your simple comment with this function that will raise and error when the time or the condition are met and remind you to do something about it.
Caution
This can cause some production apps to break ! This code is named todoordie
,
not todo_and_kittens
so be careful.
Pull-Requests are welcome to make this more production-ready !
Note this module has no warranty, see the LICENSE !
Installation
You can install the package via composer:
Usage
This will raise an error if the date is reached or passed:
This will not raise an error until the condition is met (in about 75 years):
Testing
Changelog
Please see CHANGELOG for more information on what has changed recently.
Credits
- Evangelos Dimitriadis
- All Contributors
License
The MIT License (MIT). Please see License File for more information.