Doc: Make sure _data directory is present

This commit is contained in:
nathan 2023-11-10 15:16:59 -07:00
parent 1396ba6fd4
commit 441bc8ad00

View File

@ -25,6 +25,7 @@ const allComponents = getAllComponents();
let hasBuiltSearchIndex = false;
// Write component data to file, 11ty will pick it up and create pages - the name & location are important
fs.mkdirSync("_data");
fs.writeFileSync("_data/components.json", JSON.stringify(allComponents));
// Put it here too, since addPassthroughCopy() ignores it