Manifest.json

This file is the main file of each framework project or package. All components and their dependencies are documented here.

Components

Possible components are:

Toolbar category

Furthermore, you can use the entry toolboxCategory to define where a control appears in the Visual Studio toolbar.

JavaScript Module Mapping

If JavaScript modules (ES modules) are used within this package, an import target can be defined via the entry esmoduleImports.

"esmoduleImports": [
    {
        "imports": {
            "marked": "Lib/marked.esm.js"
        }
    }
]

Such a definition can also be defined differently for a subfolder.

"esmoduleImports": [
    {
        "imports": {
            "marked": "Lib/marked.esm.js"
        }
    },
    {
        "moduleScope": "oldcontrolFolder",
        "imports": {
            "marked": "LibOld/marked.esm.js"
        }
    }
]

Example

{
   "apiVersion": 1,
   "modules": [
      {
         "type": "Package",
         "nugetId": "Beckhoff.TwinCAT.HMI.Framework"
      },
      {
         "type": "Function",
         "basePath": "myFunction/",
         "descriptionFile": "myFunction.function.json"
      },
      {
         "type": "Resource",
         "path": "customHelpers.js"
      },
      {
         "type": "Control",
         "basePath": "Control1/",
         "descriptionFile": "Description.json",
         "toolboxCategory": "MyIdentifier:200"
      },
      {
         "type": "Resource",
         "path": "PackageStyle.css"
      },
      {
         "type": "Resource",
         "path": "PackageBaseThemeStyle.css",
         "theme": "Base",
      },
      {
         "type": "Control",
         "basePath": "Control2/",
         "descriptionFile": "Description.json",
         "toolboxCategory": "MyIdentifier:201"
      }
   ],
   "provideMetadata": {
      "toolbox": {
         "MyIdentifier": {
            "200": "FrameworkPrj1",
            "201": {
               "default": "Bühnentechnik",
               "de-DE": "Bühnentechnik",
               "en-US": "Stagecraft",
               "it-IT": "Scenotecnica",
               "nl-NL": "Theatertechniek"
            }
         }
      }
   },
   "$schema": ".hmiframework/Schema/Manifest.Schema.json"
}