@openaddresses/batch-schema 7.3.0 → 7.4.0
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.
- package/CHANGELOG.md +4 -0
- package/lib/schema.js +13 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/lib/schema.js
CHANGED
|
@@ -76,6 +76,19 @@ export default class Schemas {
|
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
+
/**
|
|
80
|
+
* Load a blueprint into the router
|
|
81
|
+
*
|
|
82
|
+
* @param {Object} bp_class Blueprint Class with blueprint() fn
|
|
83
|
+
* @param {object} config Config Object
|
|
84
|
+
* @param {Object} opts Options Object
|
|
85
|
+
* @param {boolean} opts.silent Squelch StdOut
|
|
86
|
+
*/
|
|
87
|
+
async blueprint(bp_class, config, opts = {}) {
|
|
88
|
+
if (!opts.silent) console.error(`ok - loaded ${bp_class}`);
|
|
89
|
+
await bp_class.blueprint(this, config);
|
|
90
|
+
}
|
|
91
|
+
|
|
79
92
|
check(url, schemas, fns) {
|
|
80
93
|
if (typeof url !== 'string') throw new Error('URL should be string');
|
|
81
94
|
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"type": "module",
|
|
4
4
|
"root": true,
|
|
5
5
|
"main": "index.js",
|
|
6
|
-
"version": "7.
|
|
6
|
+
"version": "7.4.0",
|
|
7
7
|
"description": "Strongly Validated JSON Schema support for address",
|
|
8
8
|
"repository": "git@github.com:openaddresses/batch-schema",
|
|
9
9
|
"author": "ingalls <nick@ingalls.ca>",
|