Skip to content

Commit 41cf558

Browse files
Copilotfregante
andcommitted
Address code review feedback: add tsx as devDependency and improve comments
Co-authored-by: fregante <1402241+fregante@users.noreply.github.com>
1 parent a6156af commit 41cf558

3 files changed

Lines changed: 510 additions & 2 deletions

File tree

add-examples-to-dts.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,11 @@ for (const line of lines) {
2323
// Get the tests/examples for this function
2424
const examples = getTests(functionName);
2525

26-
// Only add examples if they exist and aren't just references to other functions
26+
// Only add examples if they exist and aren't the special 'combinedTestOnly' marker
27+
// 'combinedTestOnly' is used to skip tests for combined functions (e.g., isPageA() || isPageB())
2728
if (examples && examples.length > 0 && examples[0] !== 'combinedTestOnly') {
2829
// Filter to only include actual URLs (not references to other functions)
30+
// getTests() recursively expands function references, so we just need to filter the final list
2931
const urlExamples = examples.filter((url: string) => url.startsWith('http'));
3032

3133
if (urlExamples.length > 0) {

0 commit comments

Comments
 (0)