refactor(ui): remove superseded component scaffolds
This commit is contained in:
@@ -67,12 +67,16 @@ try {
|
||||
}
|
||||
|
||||
const referencePath = join(temporaryRoot, "packages", "ui", "component-reference.json");
|
||||
const stale = readFileSync(referencePath, "utf8").replace('"count": 108', '"count": 107');
|
||||
const canonicalCount = JSON.parse(readFileSync(referencePath, "utf8")).count;
|
||||
const stale = readFileSync(referencePath, "utf8").replace(
|
||||
`"count": ${canonicalCount}`,
|
||||
`"count": ${canonicalCount - 1}`,
|
||||
);
|
||||
writeFileSync(referencePath, stale);
|
||||
runGenerator();
|
||||
|
||||
const restored = JSON.parse(readFileSync(referencePath, "utf8"));
|
||||
if (restored.count !== 108) {
|
||||
if (restored.count !== canonicalCount) {
|
||||
throw new Error("genuinely stale component reference content was not regenerated");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user