fast-json-stringify 2.7.8 → 2.7.9

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.
@@ -22,7 +22,7 @@ jobs:
22
22
  - uses: actions/checkout@v2.3.4
23
23
 
24
24
  - name: Use Node.js
25
- uses: actions/setup-node@v2.3.0
25
+ uses: actions/setup-node@v2.4.0
26
26
  with:
27
27
  node-version: ${{ matrix.node-version }}
28
28
 
@@ -38,6 +38,6 @@ jobs:
38
38
  needs: test
39
39
  runs-on: ubuntu-latest
40
40
  steps:
41
- - uses: fastify/github-action-merge-dependabot@v2.2.0
41
+ - uses: fastify/github-action-merge-dependabot@v2.4.0
42
42
  with:
43
43
  github-token: ${{ secrets.GITHUB_TOKEN }}
package/index.d.ts CHANGED
@@ -64,6 +64,7 @@ declare namespace build {
64
64
 
65
65
  export interface StringSchema extends BaseSchema {
66
66
  type: "string";
67
+ format?: string;
67
68
  }
68
69
 
69
70
  export interface IntegerSchema extends BaseSchema {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fast-json-stringify",
3
- "version": "2.7.8",
3
+ "version": "2.7.9",
4
4
  "description": "Stringify your JSON at max speed",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -135,3 +135,11 @@ const schema11: Schema = {
135
135
  }
136
136
 
137
137
  build(schema11)({ something: 'a string', somethingElse: 42 })
138
+
139
+ // String schema with format
140
+ const schema12: Schema = {
141
+ type: 'string',
142
+ format: 'date-time'
143
+ }
144
+
145
+ build(schema12)(new Date())