Proposal
Document recommended locations, names, and minimal implementation shapes for the two TeqFW CLI integration points owned by a package or host application.
1. Package-owned CLI plugin
For a TeqFW package that declares a namespace and contributes a TeqFw_Cli_Api_Plugin, document a recommended location and naming convention:
- implementation:
src/Cli/Plugin.mjs
- component token:
<PackageNamespace>_Cli_Plugin$
- manifest:
teqfw.fw.cli.plugin
For packages with multiple CLI lifecycle concerns, src/Cli/Plugin/ may contain internal components with one aggregate Plugin.mjs, because the current manifest field accepts one DI component identifier.
Please include a minimal empty plugin example formatted according to TeqFW conventions, including JSDoc annotations:
// @ts-check
/**
* @namespace Acme_Cli_Plugin
* @description Provides the package-owned CLI lifecycle integration.
* @implements {TeqFw_Cli_Api_Plugin}
*/
export default class Plugin {
constructor() {
this.onStartup = async function () {};
this.onShutdown = async function () {};
}
}
2. Host bootstrap configurator
Document the recommended host-only location and name:
Please specify its minimal shape, including that it implements TeqFw_Cli_Api_Container_Configurator, does not construct or receive the Container, and may return empty declarative collections when no host customization is needed:
// @ts-check
/**
* @namespace Acme_Cli_Container_Configurator
* @description Provides the host composition extension point.
* @implements {TeqFw_Cli_Api_Container_Configurator}
*/
export default class Configurator {
constructor() {
/**
* @param {TeqFw_Cli_Api_Container_Configurator_Params} params
* @returns {TeqFw_Cli_Api_Container_Configurator_Configuration}
*/
this.configure = function ({applicationRoot, argv}) {
return {
namespaceRoots: [],
preprocessors: [],
postprocessors: [],
configuration: {sources: []},
};
};
}
}
The convention should remain recommended rather than filesystem-driven: CLI should continue resolving the configured components by DI identifier from package metadata.
Proposal
Document recommended locations, names, and minimal implementation shapes for the two TeqFW CLI integration points owned by a package or host application.
1. Package-owned CLI plugin
For a TeqFW package that declares a namespace and contributes a
TeqFw_Cli_Api_Plugin, document a recommended location and naming convention:src/Cli/Plugin.mjs<PackageNamespace>_Cli_Plugin$teqfw.fw.cli.pluginFor packages with multiple CLI lifecycle concerns,
src/Cli/Plugin/may contain internal components with one aggregatePlugin.mjs, because the current manifest field accepts one DI component identifier.Please include a minimal empty plugin example formatted according to TeqFW conventions, including JSDoc annotations:
2. Host bootstrap configurator
Document the recommended host-only location and name:
Please specify its minimal shape, including that it implements
TeqFw_Cli_Api_Container_Configurator, does not construct or receive the Container, and may return empty declarative collections when no host customization is needed:The convention should remain recommended rather than filesystem-driven: CLI should continue resolving the configured components by DI identifier from package metadata.