@companion-module/base 0.4.0 → 0.4.1

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 CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.4.1](https://github.com/bitfocus/companion-module-base/compare/v0.4.0...v0.4.1) (2022-10-01)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * manifest validation failing once webpacked ([afa2970](https://github.com/bitfocus/companion-module-base/commit/afa2970ca99047c7b1648005a70c82f6d3401867))
9
+
3
10
  ## [0.4.0](https://github.com/bitfocus/companion-module-base/compare/v0.3.0...v0.4.0) (2022-10-01)
4
11
 
5
12
 
@@ -1 +1 @@
1
- {"version":3,"file":"manifest.d.ts","sourceRoot":"","sources":["../src/manifest.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAA;AAItD,OAAO,EAAE,cAAc,EAAE,CAAA;AAKzB,yDAAyD;AACzD,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,cAAc,GAAG,IAAI,CAW/D"}
1
+ {"version":3,"file":"manifest.d.ts","sourceRoot":"","sources":["../src/manifest.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAA;AAItD,OAAO,EAAE,cAAc,EAAE,CAAA;AAEzB,yDAAyD;AACzD,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,cAAc,GAAG,IAAI,CAO/D"}
package/dist/manifest.js CHANGED
@@ -2,17 +2,12 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.validateManifest = void 0;
4
4
  const tslib_1 = require("tslib");
5
- const manifest_json_1 = tslib_1.__importDefault(require("../generated/manifest-json"));
6
- const ajv_1 = tslib_1.__importDefault(require("ajv"));
7
- const ajv = new ajv_1.default();
8
- let validator;
5
+ // @ts-expect-error no typings
6
+ const validate_manifest_1 = tslib_1.__importDefault(require("../generated/validate_manifest"));
9
7
  /** Validate that a manifest looks correctly populated */
10
8
  function validateManifest(manifest) {
11
- if (!validator) {
12
- validator = ajv.compile(manifest_json_1.default);
13
- }
14
- if (!validator(manifest)) {
15
- const errors = validator.errors;
9
+ if (!(0, validate_manifest_1.default)(manifest)) {
10
+ const errors = validate_manifest_1.default.errors;
16
11
  if (!errors)
17
12
  throw new Error(`Manifest failed validation with unknown reason`);
18
13
  throw new Error(`Manifest validation failed: ${JSON.stringify(errors)}`);
@@ -1 +1 @@
1
- {"version":3,"file":"manifest.js","sourceRoot":"","sources":["../src/manifest.ts"],"names":[],"mappings":";;;;AACA,uFAAuD;AACvD,sDAA2C;AAI3C,MAAM,GAAG,GAAG,IAAI,aAAG,EAAE,CAAA;AACrB,IAAI,SAAuC,CAAA;AAE3C,yDAAyD;AACzD,SAAgB,gBAAgB,CAAC,QAAwB;IACxD,IAAI,CAAC,SAAS,EAAE;QACf,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC,uBAAc,CAAC,CAAA;KACvC;IAED,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,EAAE;QACzB,MAAM,MAAM,GAAG,SAAS,CAAC,MAAM,CAAA;QAC/B,IAAI,CAAC,MAAM;YAAE,MAAM,IAAI,KAAK,CAAC,gDAAgD,CAAC,CAAA;QAE9E,MAAM,IAAI,KAAK,CAAC,+BAA+B,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,EAAE,CAAC,CAAA;KACxE;AACF,CAAC;AAXD,4CAWC"}
1
+ {"version":3,"file":"manifest.js","sourceRoot":"","sources":["../src/manifest.ts"],"names":[],"mappings":";;;;AACA,8BAA8B;AAC9B,+FAAmE;AAInE,yDAAyD;AACzD,SAAgB,gBAAgB,CAAC,QAAwB;IACxD,IAAI,CAAC,IAAA,2BAAsB,EAAC,QAAQ,CAAC,EAAE;QACtC,MAAM,MAAM,GAAG,2BAAsB,CAAC,MAAM,CAAA;QAC5C,IAAI,CAAC,MAAM;YAAE,MAAM,IAAI,KAAK,CAAC,gDAAgD,CAAC,CAAA;QAE9E,MAAM,IAAI,KAAK,CAAC,+BAA+B,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,EAAE,CAAC,CAAA;KACxE;AACF,CAAC;AAPD,4CAOC"}
@@ -0,0 +1 @@
1
+ "use strict";module.exports = validate20;module.exports.default = validate20;const schema22 = {"$schema":"http://json-schema.org/draft-07/schema#","type":"object","title":"ModuleManifest","properties":{"id":{"type":"string","description":"Unique identifier for the module"},"name":{"type":"string","description":"Name of the module"},"shortname":{"type":"string"},"description":{"type":"string","description":"Description of the module "},"version":{"type":"string","description":"Current version of the module"},"license":{"type":"string","description":"SPDX identifier for license of the module"},"repository":{"type":"string","description":"URL to the source repository"},"bugs":{"type":"string","description":"URL to bug tracker"},"maintainers":{"type":"array","description":"List of active maintiners","uniqueItems":true,"items":{"type":"object","title":"ModuleManifestMaintainer","properties":{"name":{"type":"string"},"email":{"type":"string"},"github":{"type":"string"}},"required":["name"]}},"legacyIds":{"type":"array","description":"If the module had a different unique identifier previously, then specify it here","uniqueItems":true,"items":{"type":"string"}},"runtime":{"type":"object","title":"ModuleManifestRuntime","description":"Information on how to execute the module","properties":{"type":{"type":"string","description":"Type of the module. Must be: node14"},"api":{"type":"string","description":"Which host-api does it use. Must be nodejs-ipc"},"apiVersion":{"type":"string","description":"The version of the host-api used"},"entrypoint":{"type":"string","description":"Entrypoint to pass to the runtime. eg index.js"}},"required":["type","api","apiVersion","entrypoint"]},"manufacturer":{"type":"string"},"products":{"type":"array","uniqueItems":true,"items":{"type":"string"}},"keywords":{"type":"array","uniqueItems":true,"items":{"type":"string"}}},"required":["id","name","shortname","description","version","license","repository","bugs","maintainers","legacyIds","runtime","manufacturer","products","keywords"]};const func0 = require("ajv/dist/runtime/equal").default;function validate20(data, {instancePath="", parentData, parentDataProperty, rootData=data}={}){let vErrors = null;let errors = 0;if(errors === 0){if(data && typeof data == "object" && !Array.isArray(data)){let missing0;if(((((((((((((((data.id === undefined) && (missing0 = "id")) || ((data.name === undefined) && (missing0 = "name"))) || ((data.shortname === undefined) && (missing0 = "shortname"))) || ((data.description === undefined) && (missing0 = "description"))) || ((data.version === undefined) && (missing0 = "version"))) || ((data.license === undefined) && (missing0 = "license"))) || ((data.repository === undefined) && (missing0 = "repository"))) || ((data.bugs === undefined) && (missing0 = "bugs"))) || ((data.maintainers === undefined) && (missing0 = "maintainers"))) || ((data.legacyIds === undefined) && (missing0 = "legacyIds"))) || ((data.runtime === undefined) && (missing0 = "runtime"))) || ((data.manufacturer === undefined) && (missing0 = "manufacturer"))) || ((data.products === undefined) && (missing0 = "products"))) || ((data.keywords === undefined) && (missing0 = "keywords"))){validate20.errors = [{instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: missing0},message:"must have required property '"+missing0+"'"}];return false;}else {if(data.id !== undefined){const _errs1 = errors;if(typeof data.id !== "string"){validate20.errors = [{instancePath:instancePath+"/id",schemaPath:"#/properties/id/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs1 === errors;}else {var valid0 = true;}if(valid0){if(data.name !== undefined){const _errs3 = errors;if(typeof data.name !== "string"){validate20.errors = [{instancePath:instancePath+"/name",schemaPath:"#/properties/name/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs3 === errors;}else {var valid0 = true;}if(valid0){if(data.shortname !== undefined){const _errs5 = errors;if(typeof data.shortname !== "string"){validate20.errors = [{instancePath:instancePath+"/shortname",schemaPath:"#/properties/shortname/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs5 === errors;}else {var valid0 = true;}if(valid0){if(data.description !== undefined){const _errs7 = errors;if(typeof data.description !== "string"){validate20.errors = [{instancePath:instancePath+"/description",schemaPath:"#/properties/description/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs7 === errors;}else {var valid0 = true;}if(valid0){if(data.version !== undefined){const _errs9 = errors;if(typeof data.version !== "string"){validate20.errors = [{instancePath:instancePath+"/version",schemaPath:"#/properties/version/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs9 === errors;}else {var valid0 = true;}if(valid0){if(data.license !== undefined){const _errs11 = errors;if(typeof data.license !== "string"){validate20.errors = [{instancePath:instancePath+"/license",schemaPath:"#/properties/license/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs11 === errors;}else {var valid0 = true;}if(valid0){if(data.repository !== undefined){const _errs13 = errors;if(typeof data.repository !== "string"){validate20.errors = [{instancePath:instancePath+"/repository",schemaPath:"#/properties/repository/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs13 === errors;}else {var valid0 = true;}if(valid0){if(data.bugs !== undefined){const _errs15 = errors;if(typeof data.bugs !== "string"){validate20.errors = [{instancePath:instancePath+"/bugs",schemaPath:"#/properties/bugs/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs15 === errors;}else {var valid0 = true;}if(valid0){if(data.maintainers !== undefined){let data8 = data.maintainers;const _errs17 = errors;if(errors === _errs17){if(Array.isArray(data8)){var valid1 = true;const len0 = data8.length;for(let i0=0; i0<len0; i0++){let data9 = data8[i0];const _errs19 = errors;if(errors === _errs19){if(data9 && typeof data9 == "object" && !Array.isArray(data9)){let missing1;if((data9.name === undefined) && (missing1 = "name")){validate20.errors = [{instancePath:instancePath+"/maintainers/" + i0,schemaPath:"#/properties/maintainers/items/required",keyword:"required",params:{missingProperty: missing1},message:"must have required property '"+missing1+"'"}];return false;}else {if(data9.name !== undefined){const _errs21 = errors;if(typeof data9.name !== "string"){validate20.errors = [{instancePath:instancePath+"/maintainers/" + i0+"/name",schemaPath:"#/properties/maintainers/items/properties/name/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid2 = _errs21 === errors;}else {var valid2 = true;}if(valid2){if(data9.email !== undefined){const _errs23 = errors;if(typeof data9.email !== "string"){validate20.errors = [{instancePath:instancePath+"/maintainers/" + i0+"/email",schemaPath:"#/properties/maintainers/items/properties/email/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid2 = _errs23 === errors;}else {var valid2 = true;}if(valid2){if(data9.github !== undefined){const _errs25 = errors;if(typeof data9.github !== "string"){validate20.errors = [{instancePath:instancePath+"/maintainers/" + i0+"/github",schemaPath:"#/properties/maintainers/items/properties/github/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid2 = _errs25 === errors;}else {var valid2 = true;}}}}}else {validate20.errors = [{instancePath:instancePath+"/maintainers/" + i0,schemaPath:"#/properties/maintainers/items/type",keyword:"type",params:{type: "object"},message:"must be object"}];return false;}}var valid1 = _errs19 === errors;if(!valid1){break;}}if(valid1){let i1 = data8.length;let j0;if(i1 > 1){outer0:for(;i1--;){for(j0 = i1; j0--;){if(func0(data8[i1], data8[j0])){validate20.errors = [{instancePath:instancePath+"/maintainers",schemaPath:"#/properties/maintainers/uniqueItems",keyword:"uniqueItems",params:{i: i1, j: j0},message:"must NOT have duplicate items (items ## "+j0+" and "+i1+" are identical)"}];return false;break outer0;}}}}}}else {validate20.errors = [{instancePath:instancePath+"/maintainers",schemaPath:"#/properties/maintainers/type",keyword:"type",params:{type: "array"},message:"must be array"}];return false;}}var valid0 = _errs17 === errors;}else {var valid0 = true;}if(valid0){if(data.legacyIds !== undefined){let data13 = data.legacyIds;const _errs27 = errors;if(errors === _errs27){if(Array.isArray(data13)){var valid4 = true;const len1 = data13.length;for(let i2=0; i2<len1; i2++){const _errs29 = errors;if(typeof data13[i2] !== "string"){validate20.errors = [{instancePath:instancePath+"/legacyIds/" + i2,schemaPath:"#/properties/legacyIds/items/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid4 = _errs29 === errors;if(!valid4){break;}}if(valid4){let i3 = data13.length;let j1;if(i3 > 1){const indices0 = {};for(;i3--;){let item0 = data13[i3];if(typeof item0 !== "string"){continue;}if(typeof indices0[item0] == "number"){j1 = indices0[item0];validate20.errors = [{instancePath:instancePath+"/legacyIds",schemaPath:"#/properties/legacyIds/uniqueItems",keyword:"uniqueItems",params:{i: i3, j: j1},message:"must NOT have duplicate items (items ## "+j1+" and "+i3+" are identical)"}];return false;break;}indices0[item0] = i3;}}}}else {validate20.errors = [{instancePath:instancePath+"/legacyIds",schemaPath:"#/properties/legacyIds/type",keyword:"type",params:{type: "array"},message:"must be array"}];return false;}}var valid0 = _errs27 === errors;}else {var valid0 = true;}if(valid0){if(data.runtime !== undefined){let data15 = data.runtime;const _errs31 = errors;if(errors === _errs31){if(data15 && typeof data15 == "object" && !Array.isArray(data15)){let missing2;if(((((data15.type === undefined) && (missing2 = "type")) || ((data15.api === undefined) && (missing2 = "api"))) || ((data15.apiVersion === undefined) && (missing2 = "apiVersion"))) || ((data15.entrypoint === undefined) && (missing2 = "entrypoint"))){validate20.errors = [{instancePath:instancePath+"/runtime",schemaPath:"#/properties/runtime/required",keyword:"required",params:{missingProperty: missing2},message:"must have required property '"+missing2+"'"}];return false;}else {if(data15.type !== undefined){const _errs33 = errors;if(typeof data15.type !== "string"){validate20.errors = [{instancePath:instancePath+"/runtime/type",schemaPath:"#/properties/runtime/properties/type/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid6 = _errs33 === errors;}else {var valid6 = true;}if(valid6){if(data15.api !== undefined){const _errs35 = errors;if(typeof data15.api !== "string"){validate20.errors = [{instancePath:instancePath+"/runtime/api",schemaPath:"#/properties/runtime/properties/api/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid6 = _errs35 === errors;}else {var valid6 = true;}if(valid6){if(data15.apiVersion !== undefined){const _errs37 = errors;if(typeof data15.apiVersion !== "string"){validate20.errors = [{instancePath:instancePath+"/runtime/apiVersion",schemaPath:"#/properties/runtime/properties/apiVersion/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid6 = _errs37 === errors;}else {var valid6 = true;}if(valid6){if(data15.entrypoint !== undefined){const _errs39 = errors;if(typeof data15.entrypoint !== "string"){validate20.errors = [{instancePath:instancePath+"/runtime/entrypoint",schemaPath:"#/properties/runtime/properties/entrypoint/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid6 = _errs39 === errors;}else {var valid6 = true;}}}}}}else {validate20.errors = [{instancePath:instancePath+"/runtime",schemaPath:"#/properties/runtime/type",keyword:"type",params:{type: "object"},message:"must be object"}];return false;}}var valid0 = _errs31 === errors;}else {var valid0 = true;}if(valid0){if(data.manufacturer !== undefined){const _errs41 = errors;if(typeof data.manufacturer !== "string"){validate20.errors = [{instancePath:instancePath+"/manufacturer",schemaPath:"#/properties/manufacturer/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid0 = _errs41 === errors;}else {var valid0 = true;}if(valid0){if(data.products !== undefined){let data21 = data.products;const _errs43 = errors;if(errors === _errs43){if(Array.isArray(data21)){var valid7 = true;const len2 = data21.length;for(let i4=0; i4<len2; i4++){const _errs45 = errors;if(typeof data21[i4] !== "string"){validate20.errors = [{instancePath:instancePath+"/products/" + i4,schemaPath:"#/properties/products/items/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid7 = _errs45 === errors;if(!valid7){break;}}if(valid7){let i5 = data21.length;let j2;if(i5 > 1){const indices1 = {};for(;i5--;){let item1 = data21[i5];if(typeof item1 !== "string"){continue;}if(typeof indices1[item1] == "number"){j2 = indices1[item1];validate20.errors = [{instancePath:instancePath+"/products",schemaPath:"#/properties/products/uniqueItems",keyword:"uniqueItems",params:{i: i5, j: j2},message:"must NOT have duplicate items (items ## "+j2+" and "+i5+" are identical)"}];return false;break;}indices1[item1] = i5;}}}}else {validate20.errors = [{instancePath:instancePath+"/products",schemaPath:"#/properties/products/type",keyword:"type",params:{type: "array"},message:"must be array"}];return false;}}var valid0 = _errs43 === errors;}else {var valid0 = true;}if(valid0){if(data.keywords !== undefined){let data23 = data.keywords;const _errs47 = errors;if(errors === _errs47){if(Array.isArray(data23)){var valid9 = true;const len3 = data23.length;for(let i6=0; i6<len3; i6++){const _errs49 = errors;if(typeof data23[i6] !== "string"){validate20.errors = [{instancePath:instancePath+"/keywords/" + i6,schemaPath:"#/properties/keywords/items/type",keyword:"type",params:{type: "string"},message:"must be string"}];return false;}var valid9 = _errs49 === errors;if(!valid9){break;}}if(valid9){let i7 = data23.length;let j3;if(i7 > 1){const indices2 = {};for(;i7--;){let item2 = data23[i7];if(typeof item2 !== "string"){continue;}if(typeof indices2[item2] == "number"){j3 = indices2[item2];validate20.errors = [{instancePath:instancePath+"/keywords",schemaPath:"#/properties/keywords/uniqueItems",keyword:"uniqueItems",params:{i: i7, j: j3},message:"must NOT have duplicate items (items ## "+j3+" and "+i7+" are identical)"}];return false;break;}indices2[item2] = i7;}}}}else {validate20.errors = [{instancePath:instancePath+"/keywords",schemaPath:"#/properties/keywords/type",keyword:"type",params:{type: "array"},message:"must be array"}];return false;}}var valid0 = _errs47 === errors;}else {var valid0 = true;}}}}}}}}}}}}}}}}else {validate20.errors = [{instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"}];return false;}}validate20.errors = vErrors;return errors === 0;}
package/package.json CHANGED
@@ -1,15 +1,16 @@
1
1
  {
2
2
  "name": "@companion-module/base",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "type": "commonjs",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/index.d.ts",
7
7
  "license": "MIT",
8
8
  "repository": "https://github.com/bitfocus/companion-module-base",
9
9
  "scripts": {
10
- "build": "yarn build:json-schema && yarn build:ts",
10
+ "build": "yarn build:json-schema && yarn build:ajv-validator && yarn build:ts",
11
11
  "build:ts": "tsc -p tsconfig.build.json",
12
- "build:json-schema": "json2ts --input assets/manifest.schema.json --output generated/manifest.d.ts && node scripts/wrap-json-schema.js",
12
+ "build:json-schema": "json2ts --input assets/manifest.schema.json --output generated/manifest.d.ts",
13
+ "build:ajv-validator": "ajv compile -s assets/manifest.schema.json -o generated/validate_manifest.js",
13
14
  "docs:html": "typedoc --tsconfig tsconfig.build.json --entryPoints src/index.ts --excludePrivate --theme default --out docs"
14
15
  },
15
16
  "files": [
@@ -22,7 +23,6 @@
22
23
  "dependencies": {
23
24
  "@sentry/node": "^7.14.0",
24
25
  "@sentry/tracing": "^7.14.0",
25
- "ajv": "^8.11.0",
26
26
  "ejson": "^2.2.3",
27
27
  "eventemitter3": "^4.0.7",
28
28
  "nanoid": "^3.3.4",
@@ -34,6 +34,8 @@
34
34
  "@tsconfig/node14": "^1.0.3",
35
35
  "@types/ejson": "^2.2.0",
36
36
  "@types/node": "^14.18.31",
37
+ "ajv": "^8.11.0",
38
+ "ajv-cli": "^5.0.0",
37
39
  "json-schema-to-typescript": "^11.0.2",
38
40
  "prettier": "^2.7.1",
39
41
  "typedoc": "^0.23.15",
@@ -1,2 +0,0 @@
1
- const schema: any
2
- export default schema
@@ -1,124 +0,0 @@
1
- module.exports = {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "type": "object",
4
- "title": "ModuleManifest",
5
- "properties": {
6
- "id": {
7
- "type": "string",
8
- "description": "Unique identifier for the module"
9
- },
10
- "name": {
11
- "type": "string",
12
- "description": "Name of the module"
13
- },
14
- "shortname": {
15
- "type": "string"
16
- },
17
- "description": {
18
- "type": "string",
19
- "description": "Description of the module "
20
- },
21
- "version": {
22
- "type": "string",
23
- "description": "Current version of the module"
24
- },
25
- "license": {
26
- "type": "string",
27
- "description": "SPDX identifier for license of the module"
28
- },
29
- "repository": {
30
- "type": "string",
31
- "description": "URL to the source repository"
32
- },
33
- "bugs": {
34
- "type": "string",
35
- "description": "URL to bug tracker"
36
- },
37
- "maintainers": {
38
- "type": "array",
39
- "description": "List of active maintiners",
40
- "uniqueItems": true,
41
- "items": {
42
- "type": "object",
43
- "title": "ModuleManifestMaintainer",
44
- "properties": {
45
- "name": {
46
- "type": "string"
47
- },
48
- "email": {
49
- "type": "string"
50
- },
51
- "github": {
52
- "type": "string"
53
- }
54
- },
55
- "required": ["name"]
56
- }
57
- },
58
- "legacyIds": {
59
- "type": "array",
60
- "description": "If the module had a different unique identifier previously, then specify it here",
61
- "uniqueItems": true,
62
- "items": {
63
- "type": "string"
64
- }
65
- },
66
- "runtime": {
67
- "type": "object",
68
- "title": "ModuleManifestRuntime",
69
- "description": "Information on how to execute the module",
70
- "properties": {
71
- "type": {
72
- "type": "string",
73
- "description": "Type of the module. Must be: node14"
74
- },
75
- "api": {
76
- "type": "string",
77
- "description": "Which host-api does it use. Must be nodejs-ipc"
78
- },
79
- "apiVersion": {
80
- "type": "string",
81
- "description": "The version of the host-api used"
82
- },
83
- "entrypoint": {
84
- "type": "string",
85
- "description": "Entrypoint to pass to the runtime. eg index.js"
86
- }
87
- },
88
- "required": ["type", "api", "apiVersion", "entrypoint"]
89
- },
90
- "manufacturer": {
91
- "type": "string"
92
- },
93
- "products": {
94
- "type": "array",
95
- "uniqueItems": true,
96
- "items": {
97
- "type": "string"
98
- }
99
- },
100
- "keywords": {
101
- "type": "array",
102
- "uniqueItems": true,
103
- "items": {
104
- "type": "string"
105
- }
106
- }
107
- },
108
- "required": [
109
- "id",
110
- "name",
111
- "shortname",
112
- "description",
113
- "version",
114
- "license",
115
- "repository",
116
- "bugs",
117
- "maintainers",
118
- "legacyIds",
119
- "runtime",
120
- "manufacturer",
121
- "products",
122
- "keywords"
123
- ]
124
- }