You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat: Allow ”as” ES6 keyword for Stencil’s decorators #3137
I have searched for existing issues that already include this feature request, without success.
Describe the Feature Request
The @Event and @Element decorators can be imported and can interfere with global types or be mistakenly used within the components.d.ts file. In those circumstances, it would be helpful for component authors to be able to alias the import like with the as keyword of es6 modules.
This feature allows component authors to use an aliased decorator that would be referred to within the components.d.ts file so that collisions can be reduced when interoping with global browser types.
Describe Preferred Solution
Open to perspective here, I’m not an expert on this.
Describe Alternatives
Maybe we could rename all the decorators? Or have alternate names that could be imported?
Open to perspective here, I’m not an expert on this.
Activity
rwaskiewicz commentedon Nov 9, 2021
Potentially a part of the same problem/implementation space, but not the same problem: #3037
rwaskiewicz commentedon Nov 9, 2021
Related: stenciljs/eslint-plugin#28, although not the same issue
rwaskiewicz commentedon Nov 9, 2021
This issue has been labeled to be added to our internal backlog to be discussed as a team.
pass aliased name to decorator parsers
feat(compiler): Stencil decorator import aliasing (#5161)
rwaskiewicz commentedon Dec 18, 2023
The fix for this issue has been released as a part of today's Stencil 4.9.0 release.