Files
genieacs/ui/components.js
T
Zaid Abdulla 1e41c72d60 Convert backend code to ES modules
Bundling code now with Rollup for its flat bundling and tree shaking
support. Front end code still goes through Webpack for browser support.
2019-02-04 23:47:54 -08:00

36 lines
1.1 KiB
JavaScript

"use strict";
import parameter from "./components/parameter";
import parameterList from "./components/parameter-list";
import parameterTable from "./components/parameter-table";
import overviewDot from "./components/overview-dot";
import container from "./components/container";
import summonButton from "./components/summon-button";
import deviceFaults from "./components/device-faults";
import allParameters from "./components/all-parameters";
import deviceActions from "./components/device-actions";
import tags from "./components/tags";
import ping from "./components/ping";
import deviceLink from "./components/device-link";
const comps = {
parameter,
"parameter-list": parameterList,
"parameter-table": parameterTable,
"overview-dot": overviewDot,
container,
"summon-button": summonButton,
"device-faults": deviceFaults,
"all-parameters": allParameters,
"device-actions": deviceActions,
tags,
ping,
"device-link": deviceLink
};
export function get(name) {
const c = comps[name];
if (!c) throw new Error(`No such component '${name}'`);
return c;
}