@iobroker/create-adapter
Version:
Command line utility to create customized ioBroker adapters
18 lines • 912 B
JavaScript
;
const createAdapter_1 = require("../../src/lib/createAdapter");
const templateFunction = answers => {
const useTypeScript = answers.language === "TypeScript";
const useTSWithoutBuild = answers.language === "TypeScript (without build)";
const hasTab = answers.adminFeatures && answers.adminFeatures.indexOf("tab") > -1;
const useAdminHtml = answers.adminUi === "html";
const useTabReact = hasTab && answers.tabReact === "yes";
const useTypeChecking = answers.tools && answers.tools.indexOf("type checking") > -1;
const hasHtml = useAdminHtml || (hasTab && !useTabReact);
if (!hasHtml || (!useTypeScript && !useTSWithoutBuild && !useTypeChecking)) {
return;
}
return (0, createAdapter_1.readFile)("admin.raw.d.ts", __dirname);
};
templateFunction.customPath = "admin/admin.d.ts";
module.exports = templateFunction;
//# sourceMappingURL=admin.dts.js.map