There are three types of modules: applications, site modifications and services. The modules itself are normal NPM/Node modules but special.
Application modules are simply web pages without any modifications. They are not installed on the TV, but are served from a server. The module should contain a package.json file with the following properties:
packageType: The type of the module. Should beapp.appName: The name of the module (user friendly, like "TizenTube").appPath: The path to the index.html file. (likeapp/index.html)keys: The keys that should be registered using the TVInputDevice API.serviceFile: The main JavaScript file of the service (NodeJS).evaluateScriptOnDocumentStart: Whether to evaluate the script on document start. (Before the page is fully loaded)
Site modification modules are basically the same as application modules, but they are used to modify a website. The modifications are basically JavaScript code that is injected into a website. The module should contain a package.json file with the following properties:
packageType: The type of the module. Should bemodsappName: The name of the module (user friendly, like "TizenTube").websiteURL: The URL of the website.serviceFile: The main JavaScript file of the service. Used if exists.main: The JavaScript file to be injected to the website.keys: The keys that should be registered using the TVInputDevice API.serviceFile: The main JavaScript file of the service (NodeJS).
See TizenTube for an example of an site modification module and Jellyfin-Tizen for an example of an application module.