Skip to content

bug: Relative imports of Prop/Event types from abstract component cannot be resolved in components.d.ts for subclasses #6700

@FabioGimmillaro

Description

@FabioGimmillaro

Prerequisites

Stencil Version

4.43.4

Current Behavior

When an abstract component uses imported types for Events/Props/Methods, the components.d.ts might have an error referencing said types.

Expected Behavior

When generating the components.d.ts the correct relative imports should be generated dependent on the abstract component which imports the types.

System Info

System: node 24.14.0
    Platform: windows (10.0.26200)
   CPU Model: 13th Gen Intel(R) Core(TM) i7-13620H (16 cpus)
    Compiler: C:\develop\test\node_modules\@stencil\core\compiler\stencil.js
       Build: 1776084048
     Stencil: 4.43.4
  TypeScript: 5.8.3
      Rollup: 4.44.0
      Parse5: 7.2.1
      jQuery: 4.0.0-pre
      Terser: 5.37.0

Steps to Reproduce

  • Checkout repository
  • Run "npm i"
  • Run "npm run build"
  • => Incorrect import and export of UtilType in components.d.ts

Code Reproduction URL

https://github.com/FabioGimmillaro/stencil-export-error

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug: ValidatedThis PR or Issue is verified to be a bug within Stencil

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions