@arcteninc/core 0.0.149 → 0.0.150
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/scripts/arcten-cli.cjs
CHANGED
|
File without changes
|
|
File without changes
|
|
@@ -455,39 +455,28 @@ export function filterLikelyTools(exports: DiscoveredExport[]): DiscoveredExport
|
|
|
455
455
|
return false;
|
|
456
456
|
}
|
|
457
457
|
|
|
458
|
-
// Skip
|
|
458
|
+
// Skip specific React/utility patterns (NOT general prefixes like create/get)
|
|
459
459
|
const name = exp.name.toLowerCase();
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
'debug', // debuggers
|
|
477
|
-
'trace', // tracers
|
|
478
|
-
'warn', // warners
|
|
479
|
-
'error', // error handlers
|
|
480
|
-
'handle', // handlers (too generic)
|
|
481
|
-
'on', // event handlers
|
|
482
|
-
'emit', // event emitters
|
|
483
|
-
'dispatch', // dispatchers
|
|
484
|
-
'subscribe', // subscribers
|
|
485
|
-
'unsubscribe', // unsubscribers
|
|
460
|
+
|
|
461
|
+
// Exact patterns to skip (React hooks, contexts, HOCs)
|
|
462
|
+
const skipExactPatterns = [
|
|
463
|
+
/^use[A-Z]/, // React hooks: useState, useEffect, useCallback
|
|
464
|
+
/^with[A-Z]/, // HOCs: withRouter, withAuth
|
|
465
|
+
/^create(context|store|reducer|slice|action|selector|ref|portal)$/i, // React utilities
|
|
466
|
+
/^is[A-Z][a-z]*$/, // Short type guards: isArray, isNull (but not isValidEmail)
|
|
467
|
+
/^has(own|prototype)/i, // hasOwnProperty, hasPrototype
|
|
468
|
+
/^to(string|json|array|number|boolean)$/i, // Converters
|
|
469
|
+
/^from(string|json|array|entries)$/i, // Converters
|
|
470
|
+
/^(parse|stringify)(json|int|float)?$/i, // Parsers
|
|
471
|
+
/^(assert|throw|log|debug|trace|warn|error|console)/i, // Logging/errors
|
|
472
|
+
/^(emit|dispatch|subscribe|unsubscribe)$/i, // Event system
|
|
473
|
+
/^on[A-Z]/, // Event handlers: onClick, onChange
|
|
474
|
+
/^handle[A-Z]/, // Event handlers: handleClick, handleSubmit
|
|
475
|
+
/^_/, // Private functions
|
|
486
476
|
];
|
|
487
477
|
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
if (name.startsWith(pattern) && name !== pattern) {
|
|
478
|
+
for (const pattern of skipExactPatterns) {
|
|
479
|
+
if (pattern.test(exp.name)) {
|
|
491
480
|
return false;
|
|
492
481
|
}
|
|
493
482
|
}
|
|
@@ -497,11 +486,6 @@ export function filterLikelyTools(exports: DiscoveredExport[]): DiscoveredExport
|
|
|
497
486
|
return false;
|
|
498
487
|
}
|
|
499
488
|
|
|
500
|
-
// Skip private-looking functions
|
|
501
|
-
if (exp.name.startsWith('_')) {
|
|
502
|
-
return false;
|
|
503
|
-
}
|
|
504
|
-
|
|
505
489
|
return true;
|
|
506
490
|
});
|
|
507
491
|
}
|