driftdetect-detectors 0.1.0
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/dist/accessibility/alt-text.d.ts +63 -0
- package/dist/accessibility/alt-text.d.ts.map +1 -0
- package/dist/accessibility/alt-text.js +100 -0
- package/dist/accessibility/alt-text.js.map +1 -0
- package/dist/accessibility/aria-roles.d.ts +65 -0
- package/dist/accessibility/aria-roles.d.ts.map +1 -0
- package/dist/accessibility/aria-roles.js +87 -0
- package/dist/accessibility/aria-roles.js.map +1 -0
- package/dist/accessibility/focus-management.d.ts +62 -0
- package/dist/accessibility/focus-management.d.ts.map +1 -0
- package/dist/accessibility/focus-management.js +88 -0
- package/dist/accessibility/focus-management.js.map +1 -0
- package/dist/accessibility/heading-hierarchy.d.ts +66 -0
- package/dist/accessibility/heading-hierarchy.d.ts.map +1 -0
- package/dist/accessibility/heading-hierarchy.js +94 -0
- package/dist/accessibility/heading-hierarchy.js.map +1 -0
- package/dist/accessibility/index.d.ts +25 -0
- package/dist/accessibility/index.d.ts.map +1 -0
- package/dist/accessibility/index.js +21 -0
- package/dist/accessibility/index.js.map +1 -0
- package/dist/accessibility/keyboard-nav.d.ts +63 -0
- package/dist/accessibility/keyboard-nav.d.ts.map +1 -0
- package/dist/accessibility/keyboard-nav.js +86 -0
- package/dist/accessibility/keyboard-nav.js.map +1 -0
- package/dist/accessibility/semantic-html.d.ts +76 -0
- package/dist/accessibility/semantic-html.d.ts.map +1 -0
- package/dist/accessibility/semantic-html.js +204 -0
- package/dist/accessibility/semantic-html.js.map +1 -0
- package/dist/api/client-patterns.d.ts +121 -0
- package/dist/api/client-patterns.d.ts.map +1 -0
- package/dist/api/client-patterns.js +478 -0
- package/dist/api/client-patterns.js.map +1 -0
- package/dist/api/error-format.d.ts +140 -0
- package/dist/api/error-format.d.ts.map +1 -0
- package/dist/api/error-format.js +614 -0
- package/dist/api/error-format.js.map +1 -0
- package/dist/api/http-methods.d.ts +255 -0
- package/dist/api/http-methods.d.ts.map +1 -0
- package/dist/api/http-methods.js +890 -0
- package/dist/api/http-methods.js.map +1 -0
- package/dist/api/index.d.ts +16 -0
- package/dist/api/index.d.ts.map +1 -0
- package/dist/api/index.js +37 -0
- package/dist/api/index.js.map +1 -0
- package/dist/api/pagination.d.ts +133 -0
- package/dist/api/pagination.d.ts.map +1 -0
- package/dist/api/pagination.js +521 -0
- package/dist/api/pagination.js.map +1 -0
- package/dist/api/response-envelope.d.ts +261 -0
- package/dist/api/response-envelope.d.ts.map +1 -0
- package/dist/api/response-envelope.js +1050 -0
- package/dist/api/response-envelope.js.map +1 -0
- package/dist/api/retry-patterns.d.ts +117 -0
- package/dist/api/retry-patterns.d.ts.map +1 -0
- package/dist/api/retry-patterns.js +480 -0
- package/dist/api/retry-patterns.js.map +1 -0
- package/dist/api/route-structure.d.ts +128 -0
- package/dist/api/route-structure.d.ts.map +1 -0
- package/dist/api/route-structure.js +738 -0
- package/dist/api/route-structure.js.map +1 -0
- package/dist/auth/audit-logging.d.ts +80 -0
- package/dist/auth/audit-logging.d.ts.map +1 -0
- package/dist/auth/audit-logging.js +370 -0
- package/dist/auth/audit-logging.js.map +1 -0
- package/dist/auth/index.d.ts +33 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/index.js +49 -0
- package/dist/auth/index.js.map +1 -0
- package/dist/auth/middleware-usage.d.ts +65 -0
- package/dist/auth/middleware-usage.d.ts.map +1 -0
- package/dist/auth/middleware-usage.js +192 -0
- package/dist/auth/middleware-usage.js.map +1 -0
- package/dist/auth/permission-checks.d.ts +60 -0
- package/dist/auth/permission-checks.d.ts.map +1 -0
- package/dist/auth/permission-checks.js +159 -0
- package/dist/auth/permission-checks.js.map +1 -0
- package/dist/auth/rbac-patterns.d.ts +68 -0
- package/dist/auth/rbac-patterns.d.ts.map +1 -0
- package/dist/auth/rbac-patterns.js +143 -0
- package/dist/auth/rbac-patterns.js.map +1 -0
- package/dist/auth/resource-ownership.d.ts +77 -0
- package/dist/auth/resource-ownership.d.ts.map +1 -0
- package/dist/auth/resource-ownership.js +324 -0
- package/dist/auth/resource-ownership.js.map +1 -0
- package/dist/auth/token-handling.d.ts +64 -0
- package/dist/auth/token-handling.d.ts.map +1 -0
- package/dist/auth/token-handling.js +151 -0
- package/dist/auth/token-handling.js.map +1 -0
- package/dist/base/ast-detector.d.ts +421 -0
- package/dist/base/ast-detector.d.ts.map +1 -0
- package/dist/base/ast-detector.js +699 -0
- package/dist/base/ast-detector.js.map +1 -0
- package/dist/base/base-detector.d.ts +366 -0
- package/dist/base/base-detector.d.ts.map +1 -0
- package/dist/base/base-detector.js +170 -0
- package/dist/base/base-detector.js.map +1 -0
- package/dist/base/index.d.ts +12 -0
- package/dist/base/index.d.ts.map +1 -0
- package/dist/base/index.js +17 -0
- package/dist/base/index.js.map +1 -0
- package/dist/base/regex-detector.d.ts +421 -0
- package/dist/base/regex-detector.d.ts.map +1 -0
- package/dist/base/regex-detector.js +537 -0
- package/dist/base/regex-detector.js.map +1 -0
- package/dist/base/structural-detector.d.ts +424 -0
- package/dist/base/structural-detector.d.ts.map +1 -0
- package/dist/base/structural-detector.js +731 -0
- package/dist/base/structural-detector.js.map +1 -0
- package/dist/base/types.d.ts +53 -0
- package/dist/base/types.d.ts.map +1 -0
- package/dist/base/types.js +5 -0
- package/dist/base/types.js.map +1 -0
- package/dist/components/component-structure.d.ts +163 -0
- package/dist/components/component-structure.d.ts.map +1 -0
- package/dist/components/component-structure.js +500 -0
- package/dist/components/component-structure.js.map +1 -0
- package/dist/components/composition.d.ts +287 -0
- package/dist/components/composition.d.ts.map +1 -0
- package/dist/components/composition.js +1123 -0
- package/dist/components/composition.js.map +1 -0
- package/dist/components/duplicate-detection.d.ts +251 -0
- package/dist/components/duplicate-detection.d.ts.map +1 -0
- package/dist/components/duplicate-detection.js +804 -0
- package/dist/components/duplicate-detection.js.map +1 -0
- package/dist/components/index.d.ts +16 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +51 -0
- package/dist/components/index.js.map +1 -0
- package/dist/components/near-duplicate.d.ts +402 -0
- package/dist/components/near-duplicate.d.ts.map +1 -0
- package/dist/components/near-duplicate.js +1090 -0
- package/dist/components/near-duplicate.js.map +1 -0
- package/dist/components/props-patterns.d.ts +194 -0
- package/dist/components/props-patterns.d.ts.map +1 -0
- package/dist/components/props-patterns.js +795 -0
- package/dist/components/props-patterns.js.map +1 -0
- package/dist/components/ref-forwarding.d.ts +250 -0
- package/dist/components/ref-forwarding.d.ts.map +1 -0
- package/dist/components/ref-forwarding.js +832 -0
- package/dist/components/ref-forwarding.js.map +1 -0
- package/dist/components/state-patterns.d.ts +291 -0
- package/dist/components/state-patterns.d.ts.map +1 -0
- package/dist/components/state-patterns.js +970 -0
- package/dist/components/state-patterns.js.map +1 -0
- package/dist/config/config-validation.d.ts +74 -0
- package/dist/config/config-validation.d.ts.map +1 -0
- package/dist/config/config-validation.js +446 -0
- package/dist/config/config-validation.js.map +1 -0
- package/dist/config/default-values.d.ts +72 -0
- package/dist/config/default-values.d.ts.map +1 -0
- package/dist/config/default-values.js +386 -0
- package/dist/config/default-values.js.map +1 -0
- package/dist/config/env-naming.d.ts +73 -0
- package/dist/config/env-naming.d.ts.map +1 -0
- package/dist/config/env-naming.js +429 -0
- package/dist/config/env-naming.js.map +1 -0
- package/dist/config/environment-detection.d.ts +72 -0
- package/dist/config/environment-detection.d.ts.map +1 -0
- package/dist/config/environment-detection.js +400 -0
- package/dist/config/environment-detection.js.map +1 -0
- package/dist/config/feature-flags.d.ts +72 -0
- package/dist/config/feature-flags.d.ts.map +1 -0
- package/dist/config/feature-flags.js +384 -0
- package/dist/config/feature-flags.js.map +1 -0
- package/dist/config/index.d.ts +27 -0
- package/dist/config/index.d.ts.map +1 -0
- package/dist/config/index.js +43 -0
- package/dist/config/index.js.map +1 -0
- package/dist/config/required-optional.d.ts +71 -0
- package/dist/config/required-optional.d.ts.map +1 -0
- package/dist/config/required-optional.js +344 -0
- package/dist/config/required-optional.js.map +1 -0
- package/dist/data-access/connection-pooling.d.ts +63 -0
- package/dist/data-access/connection-pooling.d.ts.map +1 -0
- package/dist/data-access/connection-pooling.js +297 -0
- package/dist/data-access/connection-pooling.js.map +1 -0
- package/dist/data-access/dto-patterns.d.ts +64 -0
- package/dist/data-access/dto-patterns.d.ts.map +1 -0
- package/dist/data-access/dto-patterns.js +291 -0
- package/dist/data-access/dto-patterns.js.map +1 -0
- package/dist/data-access/index.d.ts +31 -0
- package/dist/data-access/index.d.ts.map +1 -0
- package/dist/data-access/index.js +49 -0
- package/dist/data-access/index.js.map +1 -0
- package/dist/data-access/n-plus-one.d.ts +60 -0
- package/dist/data-access/n-plus-one.d.ts.map +1 -0
- package/dist/data-access/n-plus-one.js +264 -0
- package/dist/data-access/n-plus-one.js.map +1 -0
- package/dist/data-access/query-patterns.d.ts +64 -0
- package/dist/data-access/query-patterns.d.ts.map +1 -0
- package/dist/data-access/query-patterns.js +314 -0
- package/dist/data-access/query-patterns.js.map +1 -0
- package/dist/data-access/repository-pattern.d.ts +62 -0
- package/dist/data-access/repository-pattern.d.ts.map +1 -0
- package/dist/data-access/repository-pattern.js +257 -0
- package/dist/data-access/repository-pattern.js.map +1 -0
- package/dist/data-access/transaction-patterns.d.ts +61 -0
- package/dist/data-access/transaction-patterns.d.ts.map +1 -0
- package/dist/data-access/transaction-patterns.js +277 -0
- package/dist/data-access/transaction-patterns.js.map +1 -0
- package/dist/data-access/validation-patterns.d.ts +62 -0
- package/dist/data-access/validation-patterns.d.ts.map +1 -0
- package/dist/data-access/validation-patterns.js +301 -0
- package/dist/data-access/validation-patterns.js.map +1 -0
- package/dist/documentation/deprecation.d.ts +62 -0
- package/dist/documentation/deprecation.d.ts.map +1 -0
- package/dist/documentation/deprecation.js +83 -0
- package/dist/documentation/deprecation.js.map +1 -0
- package/dist/documentation/example-code.d.ts +64 -0
- package/dist/documentation/example-code.d.ts.map +1 -0
- package/dist/documentation/example-code.js +79 -0
- package/dist/documentation/example-code.js.map +1 -0
- package/dist/documentation/index.d.ts +22 -0
- package/dist/documentation/index.d.ts.map +1 -0
- package/dist/documentation/index.js +19 -0
- package/dist/documentation/index.js.map +1 -0
- package/dist/documentation/jsdoc-patterns.d.ts +72 -0
- package/dist/documentation/jsdoc-patterns.d.ts.map +1 -0
- package/dist/documentation/jsdoc-patterns.js +92 -0
- package/dist/documentation/jsdoc-patterns.js.map +1 -0
- package/dist/documentation/readme-structure.d.ts +67 -0
- package/dist/documentation/readme-structure.d.ts.map +1 -0
- package/dist/documentation/readme-structure.js +76 -0
- package/dist/documentation/readme-structure.js.map +1 -0
- package/dist/documentation/todo-patterns.d.ts +67 -0
- package/dist/documentation/todo-patterns.d.ts.map +1 -0
- package/dist/documentation/todo-patterns.js +73 -0
- package/dist/documentation/todo-patterns.js.map +1 -0
- package/dist/errors/async-errors.d.ts +72 -0
- package/dist/errors/async-errors.d.ts.map +1 -0
- package/dist/errors/async-errors.js +214 -0
- package/dist/errors/async-errors.js.map +1 -0
- package/dist/errors/circuit-breaker.d.ts +53 -0
- package/dist/errors/circuit-breaker.d.ts.map +1 -0
- package/dist/errors/circuit-breaker.js +241 -0
- package/dist/errors/circuit-breaker.js.map +1 -0
- package/dist/errors/error-codes.d.ts +73 -0
- package/dist/errors/error-codes.d.ts.map +1 -0
- package/dist/errors/error-codes.js +211 -0
- package/dist/errors/error-codes.js.map +1 -0
- package/dist/errors/error-logging.d.ts +73 -0
- package/dist/errors/error-logging.d.ts.map +1 -0
- package/dist/errors/error-logging.js +256 -0
- package/dist/errors/error-logging.js.map +1 -0
- package/dist/errors/error-propagation.d.ts +73 -0
- package/dist/errors/error-propagation.d.ts.map +1 -0
- package/dist/errors/error-propagation.js +244 -0
- package/dist/errors/error-propagation.js.map +1 -0
- package/dist/errors/exception-hierarchy.d.ts +75 -0
- package/dist/errors/exception-hierarchy.d.ts.map +1 -0
- package/dist/errors/exception-hierarchy.js +259 -0
- package/dist/errors/exception-hierarchy.js.map +1 -0
- package/dist/errors/index.d.ts +31 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/index.js +49 -0
- package/dist/errors/index.js.map +1 -0
- package/dist/errors/try-catch-placement.d.ts +73 -0
- package/dist/errors/try-catch-placement.d.ts.map +1 -0
- package/dist/errors/try-catch-placement.js +214 -0
- package/dist/errors/try-catch-placement.js.map +1 -0
- package/dist/index.d.ts +221 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +245 -0
- package/dist/index.js.map +1 -0
- package/dist/logging/context-fields.d.ts +48 -0
- package/dist/logging/context-fields.d.ts.map +1 -0
- package/dist/logging/context-fields.js +160 -0
- package/dist/logging/context-fields.js.map +1 -0
- package/dist/logging/correlation-ids.d.ts +44 -0
- package/dist/logging/correlation-ids.d.ts.map +1 -0
- package/dist/logging/correlation-ids.js +144 -0
- package/dist/logging/correlation-ids.js.map +1 -0
- package/dist/logging/health-checks.d.ts +45 -0
- package/dist/logging/health-checks.d.ts.map +1 -0
- package/dist/logging/health-checks.js +165 -0
- package/dist/logging/health-checks.js.map +1 -0
- package/dist/logging/index.d.ts +31 -0
- package/dist/logging/index.d.ts.map +1 -0
- package/dist/logging/index.js +49 -0
- package/dist/logging/index.js.map +1 -0
- package/dist/logging/log-levels.d.ts +46 -0
- package/dist/logging/log-levels.d.ts.map +1 -0
- package/dist/logging/log-levels.js +178 -0
- package/dist/logging/log-levels.js.map +1 -0
- package/dist/logging/metric-naming.d.ts +46 -0
- package/dist/logging/metric-naming.d.ts.map +1 -0
- package/dist/logging/metric-naming.js +157 -0
- package/dist/logging/metric-naming.js.map +1 -0
- package/dist/logging/pii-redaction.d.ts +44 -0
- package/dist/logging/pii-redaction.d.ts.map +1 -0
- package/dist/logging/pii-redaction.js +166 -0
- package/dist/logging/pii-redaction.js.map +1 -0
- package/dist/logging/structured-format.d.ts +53 -0
- package/dist/logging/structured-format.d.ts.map +1 -0
- package/dist/logging/structured-format.js +235 -0
- package/dist/logging/structured-format.js.map +1 -0
- package/dist/performance/bundle-size.d.ts +79 -0
- package/dist/performance/bundle-size.d.ts.map +1 -0
- package/dist/performance/bundle-size.js +276 -0
- package/dist/performance/bundle-size.js.map +1 -0
- package/dist/performance/caching-patterns.d.ts +78 -0
- package/dist/performance/caching-patterns.d.ts.map +1 -0
- package/dist/performance/caching-patterns.js +257 -0
- package/dist/performance/caching-patterns.js.map +1 -0
- package/dist/performance/code-splitting.d.ts +86 -0
- package/dist/performance/code-splitting.d.ts.map +1 -0
- package/dist/performance/code-splitting.js +447 -0
- package/dist/performance/code-splitting.js.map +1 -0
- package/dist/performance/debounce-throttle.d.ts +75 -0
- package/dist/performance/debounce-throttle.d.ts.map +1 -0
- package/dist/performance/debounce-throttle.js +232 -0
- package/dist/performance/debounce-throttle.js.map +1 -0
- package/dist/performance/index.d.ts +28 -0
- package/dist/performance/index.d.ts.map +1 -0
- package/dist/performance/index.js +39 -0
- package/dist/performance/index.js.map +1 -0
- package/dist/performance/lazy-loading.d.ts +75 -0
- package/dist/performance/lazy-loading.d.ts.map +1 -0
- package/dist/performance/lazy-loading.js +233 -0
- package/dist/performance/lazy-loading.js.map +1 -0
- package/dist/performance/memoization.d.ts +75 -0
- package/dist/performance/memoization.d.ts.map +1 -0
- package/dist/performance/memoization.js +251 -0
- package/dist/performance/memoization.js.map +1 -0
- package/dist/registry/detector-registry.d.ts +266 -0
- package/dist/registry/detector-registry.d.ts.map +1 -0
- package/dist/registry/detector-registry.js +526 -0
- package/dist/registry/detector-registry.js.map +1 -0
- package/dist/registry/index.d.ts +10 -0
- package/dist/registry/index.d.ts.map +1 -0
- package/dist/registry/index.js +10 -0
- package/dist/registry/index.js.map +1 -0
- package/dist/registry/loader.d.ts +232 -0
- package/dist/registry/loader.d.ts.map +1 -0
- package/dist/registry/loader.js +419 -0
- package/dist/registry/loader.js.map +1 -0
- package/dist/registry/types.d.ts +111 -0
- package/dist/registry/types.d.ts.map +1 -0
- package/dist/registry/types.js +19 -0
- package/dist/registry/types.js.map +1 -0
- package/dist/security/csp-headers.d.ts +78 -0
- package/dist/security/csp-headers.d.ts.map +1 -0
- package/dist/security/csp-headers.js +401 -0
- package/dist/security/csp-headers.js.map +1 -0
- package/dist/security/csrf-protection.d.ts +72 -0
- package/dist/security/csrf-protection.d.ts.map +1 -0
- package/dist/security/csrf-protection.js +344 -0
- package/dist/security/csrf-protection.js.map +1 -0
- package/dist/security/index.d.ts +30 -0
- package/dist/security/index.d.ts.map +1 -0
- package/dist/security/index.js +48 -0
- package/dist/security/index.js.map +1 -0
- package/dist/security/input-sanitization.d.ts +74 -0
- package/dist/security/input-sanitization.d.ts.map +1 -0
- package/dist/security/input-sanitization.js +373 -0
- package/dist/security/input-sanitization.js.map +1 -0
- package/dist/security/rate-limiting.d.ts +81 -0
- package/dist/security/rate-limiting.d.ts.map +1 -0
- package/dist/security/rate-limiting.js +535 -0
- package/dist/security/rate-limiting.js.map +1 -0
- package/dist/security/secret-management.d.ts +83 -0
- package/dist/security/secret-management.d.ts.map +1 -0
- package/dist/security/secret-management.js +547 -0
- package/dist/security/secret-management.js.map +1 -0
- package/dist/security/sql-injection.d.ts +76 -0
- package/dist/security/sql-injection.d.ts.map +1 -0
- package/dist/security/sql-injection.js +383 -0
- package/dist/security/sql-injection.js.map +1 -0
- package/dist/security/xss-prevention.d.ts +80 -0
- package/dist/security/xss-prevention.d.ts.map +1 -0
- package/dist/security/xss-prevention.js +416 -0
- package/dist/security/xss-prevention.js.map +1 -0
- package/dist/structural/barrel-exports.d.ts +178 -0
- package/dist/structural/barrel-exports.d.ts.map +1 -0
- package/dist/structural/barrel-exports.js +553 -0
- package/dist/structural/barrel-exports.js.map +1 -0
- package/dist/structural/circular-deps.d.ts +140 -0
- package/dist/structural/circular-deps.d.ts.map +1 -0
- package/dist/structural/circular-deps.js +422 -0
- package/dist/structural/circular-deps.js.map +1 -0
- package/dist/structural/co-location.d.ts +202 -0
- package/dist/structural/co-location.d.ts.map +1 -0
- package/dist/structural/co-location.js +640 -0
- package/dist/structural/co-location.js.map +1 -0
- package/dist/structural/directory-structure.d.ts +151 -0
- package/dist/structural/directory-structure.d.ts.map +1 -0
- package/dist/structural/directory-structure.js +457 -0
- package/dist/structural/directory-structure.js.map +1 -0
- package/dist/structural/file-naming.d.ts +61 -0
- package/dist/structural/file-naming.d.ts.map +1 -0
- package/dist/structural/file-naming.js +231 -0
- package/dist/structural/file-naming.js.map +1 -0
- package/dist/structural/import-ordering.d.ts +212 -0
- package/dist/structural/import-ordering.d.ts.map +1 -0
- package/dist/structural/import-ordering.js +821 -0
- package/dist/structural/import-ordering.js.map +1 -0
- package/dist/structural/index.d.ts +23 -0
- package/dist/structural/index.d.ts.map +1 -0
- package/dist/structural/index.js +26 -0
- package/dist/structural/index.js.map +1 -0
- package/dist/structural/module-boundaries.d.ts +164 -0
- package/dist/structural/module-boundaries.d.ts.map +1 -0
- package/dist/structural/module-boundaries.js +616 -0
- package/dist/structural/module-boundaries.js.map +1 -0
- package/dist/structural/package-boundaries.d.ts +182 -0
- package/dist/structural/package-boundaries.d.ts.map +1 -0
- package/dist/structural/package-boundaries.js +602 -0
- package/dist/structural/package-boundaries.js.map +1 -0
- package/dist/styling/class-naming.d.ts +263 -0
- package/dist/styling/class-naming.d.ts.map +1 -0
- package/dist/styling/class-naming.js +892 -0
- package/dist/styling/class-naming.js.map +1 -0
- package/dist/styling/color-usage.d.ts +213 -0
- package/dist/styling/color-usage.d.ts.map +1 -0
- package/dist/styling/color-usage.js +732 -0
- package/dist/styling/color-usage.js.map +1 -0
- package/dist/styling/design-tokens.d.ts +212 -0
- package/dist/styling/design-tokens.d.ts.map +1 -0
- package/dist/styling/design-tokens.js +748 -0
- package/dist/styling/design-tokens.js.map +1 -0
- package/dist/styling/index.d.ts +16 -0
- package/dist/styling/index.d.ts.map +1 -0
- package/dist/styling/index.js +56 -0
- package/dist/styling/index.js.map +1 -0
- package/dist/styling/responsive.d.ts +304 -0
- package/dist/styling/responsive.d.ts.map +1 -0
- package/dist/styling/responsive.js +888 -0
- package/dist/styling/responsive.js.map +1 -0
- package/dist/styling/spacing-scale.d.ts +248 -0
- package/dist/styling/spacing-scale.d.ts.map +1 -0
- package/dist/styling/spacing-scale.js +865 -0
- package/dist/styling/spacing-scale.js.map +1 -0
- package/dist/styling/tailwind-patterns.d.ts +305 -0
- package/dist/styling/tailwind-patterns.d.ts.map +1 -0
- package/dist/styling/tailwind-patterns.js +1181 -0
- package/dist/styling/tailwind-patterns.js.map +1 -0
- package/dist/styling/typography.d.ts +281 -0
- package/dist/styling/typography.d.ts.map +1 -0
- package/dist/styling/typography.js +1004 -0
- package/dist/styling/typography.js.map +1 -0
- package/dist/styling/z-index-scale.d.ts +270 -0
- package/dist/styling/z-index-scale.d.ts.map +1 -0
- package/dist/styling/z-index-scale.js +714 -0
- package/dist/styling/z-index-scale.js.map +1 -0
- package/dist/testing/co-location.d.ts +42 -0
- package/dist/testing/co-location.d.ts.map +1 -0
- package/dist/testing/co-location.js +134 -0
- package/dist/testing/co-location.js.map +1 -0
- package/dist/testing/describe-naming.d.ts +47 -0
- package/dist/testing/describe-naming.d.ts.map +1 -0
- package/dist/testing/describe-naming.js +150 -0
- package/dist/testing/describe-naming.js.map +1 -0
- package/dist/testing/file-naming.d.ts +44 -0
- package/dist/testing/file-naming.d.ts.map +1 -0
- package/dist/testing/file-naming.js +131 -0
- package/dist/testing/file-naming.js.map +1 -0
- package/dist/testing/fixture-patterns.d.ts +52 -0
- package/dist/testing/fixture-patterns.d.ts.map +1 -0
- package/dist/testing/fixture-patterns.js +228 -0
- package/dist/testing/fixture-patterns.js.map +1 -0
- package/dist/testing/index.d.ts +31 -0
- package/dist/testing/index.d.ts.map +1 -0
- package/dist/testing/index.js +49 -0
- package/dist/testing/index.js.map +1 -0
- package/dist/testing/mock-patterns.d.ts +53 -0
- package/dist/testing/mock-patterns.d.ts.map +1 -0
- package/dist/testing/mock-patterns.js +264 -0
- package/dist/testing/mock-patterns.js.map +1 -0
- package/dist/testing/setup-teardown.d.ts +55 -0
- package/dist/testing/setup-teardown.d.ts.map +1 -0
- package/dist/testing/setup-teardown.js +262 -0
- package/dist/testing/setup-teardown.js.map +1 -0
- package/dist/testing/test-structure.d.ts +51 -0
- package/dist/testing/test-structure.d.ts.map +1 -0
- package/dist/testing/test-structure.js +225 -0
- package/dist/testing/test-structure.js.map +1 -0
- package/dist/types/any-usage.d.ts +99 -0
- package/dist/types/any-usage.d.ts.map +1 -0
- package/dist/types/any-usage.js +641 -0
- package/dist/types/any-usage.js.map +1 -0
- package/dist/types/file-location.d.ts +76 -0
- package/dist/types/file-location.d.ts.map +1 -0
- package/dist/types/file-location.js +395 -0
- package/dist/types/file-location.js.map +1 -0
- package/dist/types/generic-patterns.d.ts +97 -0
- package/dist/types/generic-patterns.d.ts.map +1 -0
- package/dist/types/generic-patterns.js +615 -0
- package/dist/types/generic-patterns.js.map +1 -0
- package/dist/types/index.d.ts +31 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +43 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/interface-vs-type.d.ts +81 -0
- package/dist/types/interface-vs-type.d.ts.map +1 -0
- package/dist/types/interface-vs-type.js +440 -0
- package/dist/types/interface-vs-type.js.map +1 -0
- package/dist/types/naming-conventions.d.ts +84 -0
- package/dist/types/naming-conventions.d.ts.map +1 -0
- package/dist/types/naming-conventions.js +455 -0
- package/dist/types/naming-conventions.js.map +1 -0
- package/dist/types/type-assertions.d.ts +98 -0
- package/dist/types/type-assertions.d.ts.map +1 -0
- package/dist/types/type-assertions.js +639 -0
- package/dist/types/type-assertions.js.map +1 -0
- package/dist/types/utility-types.d.ts +110 -0
- package/dist/types/utility-types.d.ts.map +1 -0
- package/dist/types/utility-types.js +547 -0
- package/dist/types/utility-types.js.map +1 -0
- package/package.json +44 -0
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* File Naming Detector - File naming convention detection
|
|
3
|
+
*
|
|
4
|
+
* Detects PascalCase, kebab-case, snake_case patterns
|
|
5
|
+
* and suffix patterns (.service.ts, .test.ts).
|
|
6
|
+
*
|
|
7
|
+
* @requirements 7.1 - THE Structural_Detector SHALL detect file naming conventions
|
|
8
|
+
*/
|
|
9
|
+
import type { Violation, QuickFix, Language } from 'driftdetect-core';
|
|
10
|
+
import { StructuralDetector, type DetectionContext, type DetectionResult } from '../base/index.js';
|
|
11
|
+
export type NamingConvention = 'PascalCase' | 'camelCase' | 'kebab-case' | 'snake_case' | 'SCREAMING_SNAKE_CASE' | 'unknown';
|
|
12
|
+
export interface SuffixPattern {
|
|
13
|
+
suffix: string;
|
|
14
|
+
description: string;
|
|
15
|
+
expectedConvention?: NamingConvention;
|
|
16
|
+
}
|
|
17
|
+
export interface NamingPattern {
|
|
18
|
+
convention: NamingConvention;
|
|
19
|
+
extension: string;
|
|
20
|
+
suffix: string | undefined;
|
|
21
|
+
count: number;
|
|
22
|
+
examples: string[];
|
|
23
|
+
}
|
|
24
|
+
export interface FileNamingAnalysis {
|
|
25
|
+
fileName: string;
|
|
26
|
+
baseName: string;
|
|
27
|
+
convention: NamingConvention;
|
|
28
|
+
extension: string;
|
|
29
|
+
suffix: string | undefined;
|
|
30
|
+
followsPattern: boolean;
|
|
31
|
+
suggestedName: string | undefined;
|
|
32
|
+
}
|
|
33
|
+
export declare const COMMON_SUFFIXES: SuffixPattern[];
|
|
34
|
+
export declare function detectNamingConvention(name: string): NamingConvention;
|
|
35
|
+
export declare function convertToConvention(name: string, target: NamingConvention): string;
|
|
36
|
+
export declare function splitIntoWords(name: string): string[];
|
|
37
|
+
export declare function extractBaseName(fileName: string, suffixes?: SuffixPattern[]): {
|
|
38
|
+
baseName: string;
|
|
39
|
+
suffix: string | undefined;
|
|
40
|
+
extension: string;
|
|
41
|
+
};
|
|
42
|
+
export declare function analyzeFileName(filePath: string, dominant?: NamingConvention): FileNamingAnalysis;
|
|
43
|
+
export declare class FileNamingDetector extends StructuralDetector {
|
|
44
|
+
readonly id = "structural/file-naming";
|
|
45
|
+
readonly category: "structural";
|
|
46
|
+
readonly subcategory = "naming-conventions";
|
|
47
|
+
readonly name = "File Naming Convention Detector";
|
|
48
|
+
readonly description = "Detects file naming patterns including PascalCase, kebab-case, snake_case conventions";
|
|
49
|
+
readonly supportedLanguages: Language[];
|
|
50
|
+
detect(context: DetectionContext): Promise<DetectionResult>;
|
|
51
|
+
generateQuickFix(violation: Violation): QuickFix | null;
|
|
52
|
+
private analyzeProjectFiles;
|
|
53
|
+
private getDominantConvention;
|
|
54
|
+
private createPatternMatch;
|
|
55
|
+
private createViolation;
|
|
56
|
+
private checkSuffixPattern;
|
|
57
|
+
private isSpecialFile;
|
|
58
|
+
private calcConfidence;
|
|
59
|
+
}
|
|
60
|
+
export declare function createFileNamingDetector(): FileNamingDetector;
|
|
61
|
+
//# sourceMappingURL=file-naming.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"file-naming.d.ts","sourceRoot":"","sources":["../../src/structural/file-naming.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAgB,SAAS,EAAE,QAAQ,EAAE,QAAQ,EAAS,MAAM,kBAAkB,CAAC;AAC3F,OAAO,EAAE,kBAAkB,EAAE,KAAK,gBAAgB,EAAE,KAAK,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAMnG,MAAM,MAAM,gBAAgB,GACxB,YAAY,GACZ,WAAW,GACX,YAAY,GACZ,YAAY,GACZ,sBAAsB,GACtB,SAAS,CAAC;AAEd,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,kBAAkB,CAAC,EAAE,gBAAgB,CAAC;CACvC;AAED,MAAM,WAAW,aAAa;IAC5B,UAAU,EAAE,gBAAgB,CAAC;IAC7B,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM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AC,SAAS,EAAE,SAAS,GAAG,QAAQ,GAAG,IAAI;IAkBvD,OAAO,CAAC,mBAAmB;IAY3B,OAAO,CAAC,qBAAqB;IAO7B,OAAO,CAAC,kBAAkB;IAO1B,OAAO,CAAC,eAAe;IAqBvB,OAAO,CAAC,kBAAkB;IAuB1B,OAAO,CAAC,aAAa;IAMrB,OAAO,CAAC,cAAc;CAOvB;AAED,wBAAgB,wBAAwB,IAAI,kBAAkB,CAAqC"}
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* File Naming Detector - File naming convention detection
|
|
3
|
+
*
|
|
4
|
+
* Detects PascalCase, kebab-case, snake_case patterns
|
|
5
|
+
* and suffix patterns (.service.ts, .test.ts).
|
|
6
|
+
*
|
|
7
|
+
* @requirements 7.1 - THE Structural_Detector SHALL detect file naming conventions
|
|
8
|
+
*/
|
|
9
|
+
import { StructuralDetector } from '../base/index.js';
|
|
10
|
+
export const COMMON_SUFFIXES = [
|
|
11
|
+
{ suffix: '.service', description: 'Service file', expectedConvention: 'kebab-case' },
|
|
12
|
+
{ suffix: '.controller', description: 'Controller file', expectedConvention: 'kebab-case' },
|
|
13
|
+
{ suffix: '.model', description: 'Model file', expectedConvention: 'PascalCase' },
|
|
14
|
+
{ suffix: '.test', description: 'Test file' },
|
|
15
|
+
{ suffix: '.spec', description: 'Spec file' },
|
|
16
|
+
{ suffix: '.stories', description: 'Storybook file', expectedConvention: 'PascalCase' },
|
|
17
|
+
{ suffix: '.hook', description: 'Hook file', expectedConvention: 'camelCase' },
|
|
18
|
+
{ suffix: '.utils', description: 'Utilities file', expectedConvention: 'kebab-case' },
|
|
19
|
+
{ suffix: '.types', description: 'Types file', expectedConvention: 'kebab-case' },
|
|
20
|
+
{ suffix: '.schema', description: 'Schema file', expectedConvention: 'kebab-case' },
|
|
21
|
+
{ suffix: '.context', description: 'Context file', expectedConvention: 'PascalCase' },
|
|
22
|
+
{ suffix: '.reducer', description: 'Reducer file', expectedConvention: 'camelCase' },
|
|
23
|
+
{ suffix: '.page', description: 'Page file', expectedConvention: 'PascalCase' },
|
|
24
|
+
{ suffix: '.layout', description: 'Layout file', expectedConvention: 'PascalCase' },
|
|
25
|
+
{ suffix: '.component', description: 'Component file', expectedConvention: 'PascalCase' },
|
|
26
|
+
{ suffix: '.styles', description: 'Styles file', expectedConvention: 'kebab-case' },
|
|
27
|
+
];
|
|
28
|
+
export function detectNamingConvention(name) {
|
|
29
|
+
if (!name || name.length === 0)
|
|
30
|
+
return 'unknown';
|
|
31
|
+
if (/^[A-Z][A-Z0-9]*(_[A-Z0-9]+)*$/.test(name))
|
|
32
|
+
return 'SCREAMING_SNAKE_CASE';
|
|
33
|
+
if (/^[A-Z][a-zA-Z0-9]*$/.test(name))
|
|
34
|
+
return 'PascalCase';
|
|
35
|
+
if (/^[a-z][a-zA-Z0-9]*$/.test(name) && /[A-Z]/.test(name))
|
|
36
|
+
return 'camelCase';
|
|
37
|
+
if (/^[a-z][a-z0-9]*(-[a-z0-9]+)*$/.test(name))
|
|
38
|
+
return 'kebab-case';
|
|
39
|
+
if (/^[a-z][a-z0-9]*(_[a-z0-9]+)*$/.test(name))
|
|
40
|
+
return 'snake_case';
|
|
41
|
+
if (/^[a-z][a-z0-9]*$/.test(name))
|
|
42
|
+
return 'kebab-case';
|
|
43
|
+
return 'unknown';
|
|
44
|
+
}
|
|
45
|
+
export function convertToConvention(name, target) {
|
|
46
|
+
const words = splitIntoWords(name);
|
|
47
|
+
if (words.length === 0)
|
|
48
|
+
return name;
|
|
49
|
+
switch (target) {
|
|
50
|
+
case 'PascalCase': return words.map((w) => w.charAt(0).toUpperCase() + w.slice(1).toLowerCase()).join('');
|
|
51
|
+
case 'camelCase': return words.map((w, i) => i === 0 ? w.toLowerCase() : w.charAt(0).toUpperCase() + w.slice(1).toLowerCase()).join('');
|
|
52
|
+
case 'kebab-case': return words.map((w) => w.toLowerCase()).join('-');
|
|
53
|
+
case 'snake_case': return words.map((w) => w.toLowerCase()).join('_');
|
|
54
|
+
case 'SCREAMING_SNAKE_CASE': return words.map((w) => w.toUpperCase()).join('_');
|
|
55
|
+
default: return name;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
export function splitIntoWords(name) {
|
|
59
|
+
let n = name.replace(/[-_]/g, ' ');
|
|
60
|
+
n = n.replace(/([a-z])([A-Z])/g, '$1 $2');
|
|
61
|
+
n = n.replace(/([A-Z]+)([A-Z][a-z])/g, '$1 $2');
|
|
62
|
+
return n.split(/\s+/).filter((w) => w.length > 0);
|
|
63
|
+
}
|
|
64
|
+
export function extractBaseName(fileName, suffixes = COMMON_SUFFIXES) {
|
|
65
|
+
const lastDot = fileName.lastIndexOf('.');
|
|
66
|
+
if (lastDot === -1)
|
|
67
|
+
return { baseName: fileName, suffix: undefined, extension: '' };
|
|
68
|
+
const ext = fileName.slice(lastDot);
|
|
69
|
+
const nameNoExt = fileName.slice(0, lastDot);
|
|
70
|
+
for (const { suffix } of suffixes) {
|
|
71
|
+
if (nameNoExt.toLowerCase().endsWith(suffix.toLowerCase())) {
|
|
72
|
+
const base = nameNoExt.slice(0, -suffix.length);
|
|
73
|
+
if (base.length > 0)
|
|
74
|
+
return { baseName: base, suffix, extension: ext };
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
return { baseName: nameNoExt, suffix: undefined, extension: ext };
|
|
78
|
+
}
|
|
79
|
+
export function analyzeFileName(filePath, dominant) {
|
|
80
|
+
const fileName = filePath.split(/[/\\]/).pop() ?? filePath;
|
|
81
|
+
const { baseName, suffix, extension } = extractBaseName(fileName);
|
|
82
|
+
const convention = detectNamingConvention(baseName);
|
|
83
|
+
const followsPattern = dominant === undefined || convention === dominant;
|
|
84
|
+
let suggestedName;
|
|
85
|
+
if (!followsPattern && dominant && dominant !== 'unknown') {
|
|
86
|
+
const converted = convertToConvention(baseName, dominant);
|
|
87
|
+
suggestedName = suffix ? `${converted}${suffix}${extension}` : `${converted}${extension}`;
|
|
88
|
+
}
|
|
89
|
+
return { fileName, baseName, convention, extension, suffix, followsPattern, suggestedName };
|
|
90
|
+
}
|
|
91
|
+
export class FileNamingDetector extends StructuralDetector {
|
|
92
|
+
id = 'structural/file-naming';
|
|
93
|
+
category = 'structural';
|
|
94
|
+
subcategory = 'naming-conventions';
|
|
95
|
+
name = 'File Naming Convention Detector';
|
|
96
|
+
description = 'Detects file naming patterns including PascalCase, kebab-case, snake_case conventions';
|
|
97
|
+
supportedLanguages = ['typescript', 'javascript', 'python', 'css', 'scss', 'json', 'yaml', 'markdown'];
|
|
98
|
+
async detect(context) {
|
|
99
|
+
const patterns = [];
|
|
100
|
+
const violations = [];
|
|
101
|
+
const analysis = analyzeFileName(context.file);
|
|
102
|
+
const projectAnalysis = this.analyzeProjectFiles(context.projectContext.files);
|
|
103
|
+
if (analysis.convention !== 'unknown') {
|
|
104
|
+
patterns.push(this.createPatternMatch(context.file, analysis, projectAnalysis));
|
|
105
|
+
}
|
|
106
|
+
const dominant = this.getDominantConvention(projectAnalysis);
|
|
107
|
+
if (dominant && analysis.convention !== dominant) {
|
|
108
|
+
const v = this.createViolation(context.file, analysis, dominant);
|
|
109
|
+
if (v)
|
|
110
|
+
violations.push(v);
|
|
111
|
+
}
|
|
112
|
+
const suffixV = this.checkSuffixPattern(context.file, analysis);
|
|
113
|
+
if (suffixV)
|
|
114
|
+
violations.push(suffixV);
|
|
115
|
+
return this.createResult(patterns, violations, this.calcConfidence(projectAnalysis));
|
|
116
|
+
}
|
|
117
|
+
generateQuickFix(violation) {
|
|
118
|
+
const match = violation.message.match(/renamed to '([^']+)'/);
|
|
119
|
+
if (!match || !match[1])
|
|
120
|
+
return null;
|
|
121
|
+
const suggested = match[1];
|
|
122
|
+
const newPath = violation.file.replace(/[^/\\]+$/, suggested);
|
|
123
|
+
return {
|
|
124
|
+
title: `Rename to ${suggested}`,
|
|
125
|
+
kind: 'quickfix',
|
|
126
|
+
edit: {
|
|
127
|
+
changes: {},
|
|
128
|
+
documentChanges: [{ uri: violation.file, edits: [] }, { uri: newPath, edits: [] }],
|
|
129
|
+
},
|
|
130
|
+
isPreferred: true,
|
|
131
|
+
confidence: 0.9,
|
|
132
|
+
preview: `Rename file from '${violation.file.split(/[/\\]/).pop()}' to '${suggested}'`,
|
|
133
|
+
};
|
|
134
|
+
}
|
|
135
|
+
analyzeProjectFiles(files) {
|
|
136
|
+
const patterns = new Map();
|
|
137
|
+
for (const file of files) {
|
|
138
|
+
const a = analyzeFileName(file);
|
|
139
|
+
if (a.convention === 'unknown')
|
|
140
|
+
continue;
|
|
141
|
+
const existing = patterns.get(a.convention);
|
|
142
|
+
if (existing) {
|
|
143
|
+
existing.count++;
|
|
144
|
+
if (existing.examples.length < 5)
|
|
145
|
+
existing.examples.push(file);
|
|
146
|
+
}
|
|
147
|
+
else
|
|
148
|
+
patterns.set(a.convention, { convention: a.convention, extension: a.extension, suffix: a.suffix, count: 1, examples: [file] });
|
|
149
|
+
}
|
|
150
|
+
return patterns;
|
|
151
|
+
}
|
|
152
|
+
getDominantConvention(patterns) {
|
|
153
|
+
let maxCount = 0, dominant;
|
|
154
|
+
for (const [conv, p] of patterns) {
|
|
155
|
+
if (p.count > maxCount) {
|
|
156
|
+
maxCount = p.count;
|
|
157
|
+
dominant = conv;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
const total = Array.from(patterns.values()).reduce((s, p) => s + p.count, 0);
|
|
161
|
+
return dominant && maxCount / total > 0.5 ? dominant : undefined;
|
|
162
|
+
}
|
|
163
|
+
createPatternMatch(file, analysis, projectAnalysis) {
|
|
164
|
+
const p = projectAnalysis.get(analysis.convention);
|
|
165
|
+
const total = Array.from(projectAnalysis.values()).reduce((s, x) => s + x.count, 0);
|
|
166
|
+
const freq = p ? p.count / total : 0;
|
|
167
|
+
return { patternId: `file-naming-${analysis.convention}`, location: { file, line: 1, column: 1 }, confidence: freq, isOutlier: freq < 0.5 };
|
|
168
|
+
}
|
|
169
|
+
createViolation(file, analysis, dominant) {
|
|
170
|
+
const fileName = file.split(/[/\\]/).pop() ?? '';
|
|
171
|
+
if (this.isSpecialFile(fileName))
|
|
172
|
+
return null;
|
|
173
|
+
const suggested = analysis.suggestedName ?? convertToConvention(analysis.baseName, dominant) + (analysis.suffix ?? '') + analysis.extension;
|
|
174
|
+
const range = { start: { line: 1, character: 1 }, end: { line: 1, character: 1 } };
|
|
175
|
+
return {
|
|
176
|
+
id: `file-naming-${file.replace(/[^a-zA-Z0-9]/g, '-')}`,
|
|
177
|
+
patternId: 'structural/file-naming',
|
|
178
|
+
severity: 'warning',
|
|
179
|
+
file,
|
|
180
|
+
range,
|
|
181
|
+
message: `File '${fileName}' uses ${analysis.convention} but project uses ${dominant}. It should be renamed to '${suggested}'`,
|
|
182
|
+
expected: `${dominant} naming convention`,
|
|
183
|
+
actual: `${analysis.convention} naming convention`,
|
|
184
|
+
aiExplainAvailable: false,
|
|
185
|
+
aiFixAvailable: true,
|
|
186
|
+
firstSeen: new Date(),
|
|
187
|
+
occurrences: 1,
|
|
188
|
+
};
|
|
189
|
+
}
|
|
190
|
+
checkSuffixPattern(file, analysis) {
|
|
191
|
+
if (!analysis.suffix)
|
|
192
|
+
return null;
|
|
193
|
+
const sp = COMMON_SUFFIXES.find((s) => s.suffix.toLowerCase() === analysis.suffix?.toLowerCase());
|
|
194
|
+
if (!sp?.expectedConvention || analysis.convention === sp.expectedConvention || analysis.convention === 'unknown')
|
|
195
|
+
return null;
|
|
196
|
+
const suggestedBase = convertToConvention(analysis.baseName, sp.expectedConvention);
|
|
197
|
+
const suggested = `${suggestedBase}${analysis.suffix}${analysis.extension}`;
|
|
198
|
+
const range = { start: { line: 1, character: 1 }, end: { line: 1, character: 1 } };
|
|
199
|
+
return {
|
|
200
|
+
id: `file-naming-suffix-${file.replace(/[^a-zA-Z0-9]/g, '-')}`,
|
|
201
|
+
patternId: 'structural/file-naming-suffix',
|
|
202
|
+
severity: 'info',
|
|
203
|
+
file,
|
|
204
|
+
range,
|
|
205
|
+
message: `${sp.description} '${analysis.fileName}' should use ${sp.expectedConvention} naming. It should be renamed to '${suggested}'`,
|
|
206
|
+
expected: `${sp.expectedConvention} naming for ${sp.description.toLowerCase()}`,
|
|
207
|
+
actual: `${analysis.convention} naming`,
|
|
208
|
+
aiExplainAvailable: false,
|
|
209
|
+
aiFixAvailable: true,
|
|
210
|
+
firstSeen: new Date(),
|
|
211
|
+
occurrences: 1,
|
|
212
|
+
};
|
|
213
|
+
}
|
|
214
|
+
isSpecialFile(fileName) {
|
|
215
|
+
const special = ['index', 'main', 'app', 'readme', 'license', 'changelog', 'dockerfile', 'makefile', 'package', 'tsconfig', 'eslint', 'prettier', 'jest', 'vitest', 'vite', 'webpack', 'rollup', 'babel', 'postcss', 'tailwind', 'next'];
|
|
216
|
+
const lower = fileName.toLowerCase().replace(/\.[^.]+$/, '');
|
|
217
|
+
return special.some((s) => lower === s || lower.startsWith(`${s}.`));
|
|
218
|
+
}
|
|
219
|
+
calcConfidence(patterns) {
|
|
220
|
+
const total = Array.from(patterns.values()).reduce((s, p) => s + p.count, 0);
|
|
221
|
+
if (total === 0)
|
|
222
|
+
return 0.5;
|
|
223
|
+
let max = 0;
|
|
224
|
+
for (const p of patterns.values())
|
|
225
|
+
if (p.count > max)
|
|
226
|
+
max = p.count;
|
|
227
|
+
return Math.min(max / total + 0.2, 1.0);
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
export function createFileNamingDetector() { return new FileNamingDetector(); }
|
|
231
|
+
//# sourceMappingURL=file-naming.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"file-naming.js","sourceRoot":"","sources":["../../src/structural/file-naming.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,EAAE,kBAAkB,EAA+C,MAAM,kBAAkB,CAAC;AAsCnG,MAAM,CAAC,MAAM,eAAe,GAAoB;IAC9C,EAAE,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,cAAc,EAAE,kBAAkB,EAAE,YAAY,EAAE;I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AE,SAAS,EAAE,UAAU,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,CAAC,CAAC;QACzO,MAAM,KAAK,GAAG,QAAQ,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC;QAC7D,OAAO,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,KAAK,KAAK,CAAC,IAAI,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,CAAC;IACvE,CAAC;IAEO,cAAc,CAAC,QAA8C;QACnE,MAAM,KAAK,GAAG,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC;QAC7E,IAAI,KAAK,KAAK,CAAC;YAAE,OAAO,GAAG,CAAC;QAC5B,IAAI,GAAG,GAAG,CAAC,CAAC;QACZ,KAAK,MAAM,CAAC,IAAI,QAAQ,CAAC,MAAM,EAAE;YAAE,IAAI,CAAC,CAAC,KAAK,GAAG,GAAG;gBAAE,GAAG,GAAG,CAAC,CAAC,KAAK,CAAC;QACpE,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,GAAG,KAAK,GAAG,GAAG,EAAE,GAAG,CAAC,CAAC;IAC1C,CAAC;CACF;AAED,MAAM,UAAU,wBAAwB,KAAyB,OAAO,IAAI,kBAAkB,EAAE,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Import Ordering Detector - Import organization detection
|
|
3
|
+
*
|
|
4
|
+
* Detects import grouping patterns and import sorting patterns.
|
|
5
|
+
* Identifies how imports are organized (external packages first, then internal modules,
|
|
6
|
+
* then relative imports), whether they are sorted alphabetically within groups,
|
|
7
|
+
* and whether blank lines separate groups.
|
|
8
|
+
*
|
|
9
|
+
* @requirements 7.5 - THE Structural_Detector SHALL detect import ordering and grouping patterns
|
|
10
|
+
*/
|
|
11
|
+
import type { Violation, QuickFix, Language } from 'driftdetect-core';
|
|
12
|
+
import { StructuralDetector, type DetectionContext, type DetectionResult } from '../base/index.js';
|
|
13
|
+
/**
|
|
14
|
+
* Types of import grouping patterns
|
|
15
|
+
*/
|
|
16
|
+
export type ImportGroupingPattern = 'grouped' | 'ungrouped' | 'mixed' | 'unknown';
|
|
17
|
+
/**
|
|
18
|
+
* Types of import sorting patterns
|
|
19
|
+
*/
|
|
20
|
+
export type ImportSortingPattern = 'alphabetical' | 'unsorted' | 'mixed' | 'unknown';
|
|
21
|
+
/**
|
|
22
|
+
* Types of imports based on their source
|
|
23
|
+
*/
|
|
24
|
+
export type ImportType = 'builtin' | 'external' | 'internal' | 'parent' | 'sibling' | 'index';
|
|
25
|
+
/**
|
|
26
|
+
* Common Node.js built-in modules
|
|
27
|
+
*/
|
|
28
|
+
export declare const BUILTIN_MODULES: readonly ["assert", "buffer", "child_process", "cluster", "console", "constants", "crypto", "dgram", "dns", "domain", "events", "fs", "http", "https", "module", "net", "os", "path", "perf_hooks", "process", "punycode", "querystring", "readline", "repl", "stream", "string_decoder", "sys", "timers", "tls", "tty", "url", "util", "v8", "vm", "worker_threads", "zlib", "node:assert", "node:buffer", "node:child_process", "node:cluster", "node:console", "node:constants", "node:crypto", "node:dgram", "node:dns", "node:domain", "node:events", "node:fs", "node:http", "node:https", "node:module", "node:net", "node:os", "node:path", "node:perf_hooks", "node:process", "node:punycode", "node:querystring", "node:readline", "node:repl", "node:stream", "node:string_decoder", "node:sys", "node:timers", "node:tls", "node:tty", "node:url", "node:util", "node:v8", "node:vm", "node:worker_threads", "node:zlib"];
|
|
29
|
+
/**
|
|
30
|
+
* Common internal alias patterns
|
|
31
|
+
* Note: @types/ is excluded as it's an external package namespace
|
|
32
|
+
*/
|
|
33
|
+
export declare const INTERNAL_ALIAS_PATTERNS: readonly [RegExp, RegExp, RegExp, RegExp];
|
|
34
|
+
/**
|
|
35
|
+
* Information about a single import statement
|
|
36
|
+
*/
|
|
37
|
+
export interface ImportInfo {
|
|
38
|
+
/** The import source/specifier */
|
|
39
|
+
source: string;
|
|
40
|
+
/** The type of import */
|
|
41
|
+
type: ImportType;
|
|
42
|
+
/** Line number where the import appears */
|
|
43
|
+
line: number;
|
|
44
|
+
/** The full import statement text */
|
|
45
|
+
statement: string;
|
|
46
|
+
/** Whether this is a type-only import */
|
|
47
|
+
isTypeOnly: boolean;
|
|
48
|
+
/** Whether this is a side-effect import (no specifiers) */
|
|
49
|
+
isSideEffect: boolean;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Information about a group of imports
|
|
53
|
+
*/
|
|
54
|
+
export interface ImportGroup {
|
|
55
|
+
/** The type of imports in this group */
|
|
56
|
+
type: ImportType;
|
|
57
|
+
/** Imports in this group */
|
|
58
|
+
imports: ImportInfo[];
|
|
59
|
+
/** Starting line of the group */
|
|
60
|
+
startLine: number;
|
|
61
|
+
/** Ending line of the group */
|
|
62
|
+
endLine: number;
|
|
63
|
+
/** Whether imports in this group are sorted alphabetically */
|
|
64
|
+
isSorted: boolean;
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* Analysis of import ordering patterns in a file
|
|
68
|
+
*/
|
|
69
|
+
export interface FileImportAnalysis {
|
|
70
|
+
/** All imports found in the file */
|
|
71
|
+
imports: ImportInfo[];
|
|
72
|
+
/** Import groups detected */
|
|
73
|
+
groups: ImportGroup[];
|
|
74
|
+
/** Whether imports are grouped by type */
|
|
75
|
+
isGrouped: boolean;
|
|
76
|
+
/** Whether blank lines separate groups */
|
|
77
|
+
hasBlankLineSeparators: boolean;
|
|
78
|
+
/** Whether imports are sorted within groups */
|
|
79
|
+
isSortedWithinGroups: boolean;
|
|
80
|
+
/** The detected group order (e.g., ['builtin', 'external', 'internal', 'parent', 'sibling']) */
|
|
81
|
+
groupOrder: ImportType[];
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Analysis of import ordering patterns across a project
|
|
85
|
+
*/
|
|
86
|
+
export interface ImportOrderingAnalysis {
|
|
87
|
+
/** Detected grouping pattern */
|
|
88
|
+
groupingPattern: ImportGroupingPattern;
|
|
89
|
+
/** Detected sorting pattern */
|
|
90
|
+
sortingPattern: ImportSortingPattern;
|
|
91
|
+
/** Confidence in the detection (0-1) */
|
|
92
|
+
confidence: number;
|
|
93
|
+
/** Files analyzed */
|
|
94
|
+
filesAnalyzed: number;
|
|
95
|
+
/** Files with grouped imports */
|
|
96
|
+
filesWithGroupedImports: number;
|
|
97
|
+
/** Files with sorted imports */
|
|
98
|
+
filesWithSortedImports: number;
|
|
99
|
+
/** Files with blank line separators */
|
|
100
|
+
filesWithBlankLineSeparators: number;
|
|
101
|
+
/** Most common group order */
|
|
102
|
+
dominantGroupOrder: ImportType[];
|
|
103
|
+
/** Percentage of files following the dominant pattern */
|
|
104
|
+
patternConsistency: number;
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Python standard library modules (subset of most common)
|
|
108
|
+
*/
|
|
109
|
+
export declare const PYTHON_STDLIB_MODULES: readonly ["abc", "argparse", "asyncio", "base64", "collections", "contextlib", "copy", "csv", "dataclasses", "datetime", "decimal", "enum", "functools", "hashlib", "http", "importlib", "inspect", "io", "itertools", "json", "logging", "math", "multiprocessing", "os", "pathlib", "pickle", "random", "re", "shutil", "socket", "sqlite3", "ssl", "string", "subprocess", "sys", "tempfile", "threading", "time", "traceback", "typing", "unittest", "urllib", "uuid", "warnings", "xml", "zipfile"];
|
|
110
|
+
/**
|
|
111
|
+
* Determine the type of a Python import based on its source
|
|
112
|
+
*/
|
|
113
|
+
export declare function getPythonImportType(source: string): ImportType;
|
|
114
|
+
/**
|
|
115
|
+
* Parse Python import statements from file content
|
|
116
|
+
*/
|
|
117
|
+
export declare function parsePythonImports(content: string): ImportInfo[];
|
|
118
|
+
/**
|
|
119
|
+
* Determine the type of an import based on its source
|
|
120
|
+
*/
|
|
121
|
+
export declare function getImportType(source: string): ImportType;
|
|
122
|
+
/**
|
|
123
|
+
* Parse import statements from file content
|
|
124
|
+
*/
|
|
125
|
+
export declare function parseImports(content: string, filePath?: string): ImportInfo[];
|
|
126
|
+
/**
|
|
127
|
+
* Check if imports are sorted alphabetically
|
|
128
|
+
*/
|
|
129
|
+
export declare function areImportsSorted(imports: ImportInfo[]): boolean;
|
|
130
|
+
/**
|
|
131
|
+
* Detect import groups based on blank lines and import types
|
|
132
|
+
*/
|
|
133
|
+
export declare function detectImportGroups(imports: ImportInfo[], content: string): ImportGroup[];
|
|
134
|
+
/**
|
|
135
|
+
* Check if groups are separated by blank lines
|
|
136
|
+
*/
|
|
137
|
+
export declare function hasBlankLineSeparators(groups: ImportGroup[], content: string): boolean;
|
|
138
|
+
/**
|
|
139
|
+
* Check if imports are grouped by type
|
|
140
|
+
*/
|
|
141
|
+
export declare function areImportsGroupedByType(groups: ImportGroup[]): boolean;
|
|
142
|
+
/**
|
|
143
|
+
* Get the order of import types from groups
|
|
144
|
+
*/
|
|
145
|
+
export declare function getGroupOrder(groups: ImportGroup[]): ImportType[];
|
|
146
|
+
/**
|
|
147
|
+
* Analyze import ordering in a single file
|
|
148
|
+
*/
|
|
149
|
+
export declare function analyzeFileImports(content: string, filePath?: string): FileImportAnalysis;
|
|
150
|
+
/**
|
|
151
|
+
* Analyze import ordering patterns across multiple files
|
|
152
|
+
*/
|
|
153
|
+
export declare function analyzeImportOrdering(fileContents: Map<string, string>): ImportOrderingAnalysis;
|
|
154
|
+
/**
|
|
155
|
+
* Get the expected group order description
|
|
156
|
+
*/
|
|
157
|
+
export declare function getGroupOrderDescription(order: ImportType[]): string;
|
|
158
|
+
/**
|
|
159
|
+
* Detector for import ordering and grouping patterns
|
|
160
|
+
*
|
|
161
|
+
* Identifies how imports are organized in a project:
|
|
162
|
+
* - Grouping by type (external, internal, relative)
|
|
163
|
+
* - Alphabetical sorting within groups
|
|
164
|
+
* - Blank line separators between groups
|
|
165
|
+
*
|
|
166
|
+
* @requirements 7.5 - THE Structural_Detector SHALL detect import ordering and grouping patterns
|
|
167
|
+
*/
|
|
168
|
+
export declare class ImportOrderingDetector extends StructuralDetector {
|
|
169
|
+
readonly id = "structural/import-ordering";
|
|
170
|
+
readonly category: "structural";
|
|
171
|
+
readonly subcategory = "import-ordering";
|
|
172
|
+
readonly name = "Import Ordering Detector";
|
|
173
|
+
readonly description = "Detects import grouping and sorting patterns";
|
|
174
|
+
readonly supportedLanguages: Language[];
|
|
175
|
+
/**
|
|
176
|
+
* Detect import ordering patterns in the project
|
|
177
|
+
*/
|
|
178
|
+
detect(context: DetectionContext): Promise<DetectionResult>;
|
|
179
|
+
/**
|
|
180
|
+
* Generate a quick fix for import ordering violations
|
|
181
|
+
*/
|
|
182
|
+
generateQuickFix(violation: Violation): QuickFix | null;
|
|
183
|
+
/**
|
|
184
|
+
* Create a pattern match for import grouping
|
|
185
|
+
*/
|
|
186
|
+
private createGroupingPattern;
|
|
187
|
+
/**
|
|
188
|
+
* Create a pattern match for import sorting
|
|
189
|
+
*/
|
|
190
|
+
private createSortingPattern;
|
|
191
|
+
/**
|
|
192
|
+
* Create a pattern match for group order
|
|
193
|
+
*/
|
|
194
|
+
private createGroupOrderPattern;
|
|
195
|
+
/**
|
|
196
|
+
* Check if the file's import grouping follows the project pattern
|
|
197
|
+
*/
|
|
198
|
+
private checkGroupingConsistency;
|
|
199
|
+
/**
|
|
200
|
+
* Check if the file's import sorting follows the project pattern
|
|
201
|
+
*/
|
|
202
|
+
private checkSortingConsistency;
|
|
203
|
+
/**
|
|
204
|
+
* Check if the file uses blank line separators between import groups
|
|
205
|
+
*/
|
|
206
|
+
private checkBlankLineSeparators;
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Create a new ImportOrderingDetector instance
|
|
210
|
+
*/
|
|
211
|
+
export declare function createImportOrderingDetector(): ImportOrderingDetector;
|
|
212
|
+
//# sourceMappingURL=import-ordering.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"import-ordering.d.ts","sourceRoot":"","sources":["../../src/structural/import-ordering.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAgB,SAAS,EAAE,QAAQ,EAAE,QAAQ,EAAS,MAAM,kBAAkB,CAAC;AAC3F,OAAO,EAAE,kBAAkB,EAAE,KAAK,gBAAgB,EAAE,KAAK,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAMnG;;GAEG;AACH,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG,WAAW,GAAG,OAAO,GAAG,SAAS,CAAC;AAElF;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG,cAAc,GAAG,UAAU,GAAG,OAAO,GAAG,SAAS,CAAC;AAErF;;GAEG;AACH,MAAM,MAAM,UAAU,GAClB,SAAS,GACT,UAAU,GACV,UAAU,GACV,QAAQ,GACR,SAAS,GACT,OAAO,CAAC;AAEZ;;GAEG;AACH,eAAO,MAAM,eAAe,u4BAelB,CAAC;AAEX;;;GAGG;AACH,eAAO,MAAM,uBAAuB,2CAK1B,CAAC;AAEX;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,kCAAkC;IAClC,MAAM,EAAE,MAAM,CAAC;IACf,yBAAyB;IACzB,IAAI,EAAE,UAAU,CAAC;IACjB,2CAA2C;IAC3C,IAAI,EAAE,MAAM,CAAC;IACb,qCAAqC;IACrC,SAAS,EAAE,MAAM,CAAC;IAClB,yCAAyC;IACzC,UAAU,EAAE,OAAO,CAAC;IACpB,2DAA2D;IAC3D,YAAY,EAAE,OAAO,CAAC;CACvB;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,wCAAwC;IACxC,IAAI,EAAE,UAAU,CAAC;IACjB,4BAA4B;IAC5B,OAAO,EAAE,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