go-mokapi 0.9.0 → 0.9.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "go-mokapi",
3
- "version": "0.9.0",
3
+ "version": "0.9.2",
4
4
  "description": "Easy and flexible API mocking",
5
5
  "homepage": "https://mokapi.io",
6
6
  "repository": {
package/types/mokapi.d.ts CHANGED
@@ -27,7 +27,9 @@ declare module 'mokapi' {
27
27
  */
28
28
  function cron(expr: string, f: ScheduledEventHandler, args?: ScheduledEventArgs): void
29
29
 
30
- /** Returns the environment variable named by the key. */
30
+ /** Retrieves the value of the environment variable named by the key.
31
+ It returns the value, which will be empty if the variable is not present.
32
+ */
31
33
  function env(name: string): string
32
34
 
33
35
  /** Opens a file and reading all its content. */
@@ -100,10 +102,12 @@ declare interface Url {
100
102
  }
101
103
 
102
104
  declare interface DateArgs {
103
- layout?: string
105
+ layout?: DateLayout
104
106
  timestamp?: number
105
107
  }
106
108
 
109
+ declare type DateLayout = 'DateTime' | 'DateOnly' | 'TimeOnly' | 'UnixDate' | 'RFC882' | 'RFC822Z' | 'RFC850' | 'RFC1123' | 'RFC1123Z' | 'RFC3339' | 'RFC3339Nano'
110
+
107
111
  declare interface EventArgs {
108
112
  /**
109
113
  * Adds or overrides existing tags used in dashboard