chore: fix issue in the check.js script (#7965)
This commit is contained in:
parent
8ea6b6dedf
commit
0fd6dc7ec7
1 changed files with 27 additions and 24 deletions
|
@ -18,7 +18,8 @@ function checkExamples() {
|
|||
|
||||
for (const example of examples) {
|
||||
checkPromises.push(
|
||||
limit(() =>
|
||||
limit(
|
||||
() =>
|
||||
new Promise((resolve) => {
|
||||
const originalConfig = prepareExample(example.name);
|
||||
let data = '';
|
||||
|
@ -42,7 +43,7 @@ function checkExamples() {
|
|||
});
|
||||
})
|
||||
)
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
Promise.all(checkPromises).then((codes) => {
|
||||
|
@ -50,7 +51,7 @@ function checkExamples() {
|
|||
process.exit(1);
|
||||
}
|
||||
|
||||
console.log("No errors found!");
|
||||
console.log('No errors found!');
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -75,7 +76,9 @@ function prepareExample(examplePath) {
|
|||
});
|
||||
}
|
||||
|
||||
if (tsconfig.config) {
|
||||
writeFileSync(tsconfigPath, JSON.stringify(tsconfig.config));
|
||||
}
|
||||
|
||||
return originalConfig;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue