Comparing version 4.0.71 to 4.0.72
{ | ||
"name": "croner", | ||
"version": "4.0.71", | ||
"version": "4.0.72", | ||
"description": "Trigger functions in javascript using Cron syntax. No deps. All features.", | ||
@@ -26,3 +26,4 @@ "author": "Hexagon <github.com/hexagon>", | ||
"SECURITY.md", | ||
"croner.png" | ||
"croner.png", | ||
"mod.ts" | ||
], | ||
@@ -29,0 +30,0 @@ "keywords": [ |
@@ -14,3 +14,4 @@ <p align="center"> | ||
* Find first date of next month, find date of next tuesday, etc. | ||
* Works in Node.js >=4.0 (require and import) | ||
* Works in Node.js >=4.0 (both require and import) | ||
* Works in Deno >=1.16 | ||
* Works in browsers as standalone, UMD or ES-module. | ||
@@ -53,2 +54,24 @@ * **Experimental feature:** Schedule in specific target timezones | ||
### Deno | ||
JavaScript | ||
```javascript | ||
import Cron from "https://cdn.jsdelivr.net/npm/croner@4/mod.ts"; | ||
Cron("* * * * * *", () => { | ||
console.log("This will run every second."); | ||
}); | ||
``` | ||
TypeScript | ||
```typescript | ||
import { Cron } from "https://cdn.jsdelivr.net/npm/croner@4/mod.ts"; | ||
let scheduler : Cron = new Cron("* * * * * *", {}, () => { | ||
console.log("This will run every second."); | ||
}); | ||
``` | ||
### Browser | ||
@@ -55,0 +78,0 @@ |
@@ -60,3 +60,3 @@ /* ------------------------------------------------------------------------------------ | ||
* @param {string} pattern - Input pattern | ||
* @param {CronOptions} [options] - Options | ||
* @param {CronOptions|Function} [options] - Options | ||
* @param {Function} [func] - Function to be run each iteration of pattern | ||
@@ -63,0 +63,0 @@ * @returns {Cron} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
111693
22
1720
225