2023-05-11 13:27:25 +00:00
|
|
|
import { DeclarationDataCenter } from "./declaration-data.js";
|
|
|
|
|
|
|
|
fillImportedBy();
|
|
|
|
|
|
|
|
async function fillImportedBy() {
|
2023-11-08 01:36:00 +00:00
|
|
|
if (typeof(MODULE_NAME) == "undefined") {
|
2023-05-11 13:27:25 +00:00
|
|
|
return;
|
|
|
|
}
|
|
|
|
const dataCenter = await DeclarationDataCenter.init();
|
|
|
|
const moduleName = MODULE_NAME;
|
|
|
|
const importedByList = document.querySelector(".imported-by-list");
|
|
|
|
const importedBy = dataCenter.moduleImportedBy(moduleName);
|
|
|
|
var innerHTML = "";
|
|
|
|
for(var module of importedBy) {
|
|
|
|
const moduleLink = dataCenter.moduleNameToLink(module);
|
|
|
|
innerHTML += `<li><a href="${SITE_ROOT}${moduleLink}">${module}</a></li>`
|
|
|
|
}
|
|
|
|
importedByList.innerHTML = innerHTML;
|
|
|
|
}
|