Skip to content

Commit 1382d7d

Browse files
committed
docs: tags as constants
1 parent 52d661e commit 1382d7d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,10 @@ composer require adhocore/cron-expr:0.1.0
2828

2929
```php
3030
use Ahc\Cron\Expression;
31+
use Ahc\Cron\Normalizer;
3132

3233
Expression::isDue('@always');
33-
Expression::isDue('@hourly', '2015-01-01 00:00:00');
34+
Expression::isDue(Normalizer::HOURLY, '2015-01-01 00:00:00');
3435
Expression::isDue('*/20 * * * *', new DateTime);
3536
Expression::isDue('5-34/4 * * * *', time());
3637

@@ -92,6 +93,8 @@ Following tags are available and they are converted to real cron expressions bef
9293
- *@30minutes* - every 30 minutes
9394
- *@always* - every minute
9495

96+
> You can refer them with constants from `Ahc\Cron\Normalizer` like `Ahc\Cron\Normalizer::WEEKLY`
97+
9598
### Modifiers
9699

97100
Following modifiers supported

0 commit comments

Comments
 (0)