feature: language server support for a richer editing experience for Stencil components
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 32/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- angular, typescript
- Domain
- frontend
Research direction
Start with the component.tsx type and @Prop example, then inspect the generated package and interfaces.d.ts guidance before reproducing use in app.component.html with Angular 16.2. Confirm how the custom union is represented across the package boundary and whether Angular receives it. Done means the exported component exposes primary-500 and secondary-500 as the color property's available types.
Written by the indexing model from the issue text.
Description
Prerequisites
- I have read the Contributing Guidelines.
- I agree to follow the Code of Conduct.
- I have searched for existing issues that already report this problem, without success.
Stencil Version
4.11
Current Behavior
Working with custom types created by myself in Stencil work great if I'm using them in others custom components in stencil.
But when I create a npm package for using my components into Angular 16.2 I can't have the custom types.
Expected Behavior
I would like to be able to use the custom types created with stencil in angular
System Info
System: node 18.19.0
Platform: windows (10.0.19045)
CPU Model: Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (8 cpus)
Compiler: C:\Users\lsciampagna\Desktop\web\ap\starter-web components\node_modules\@stencil\core\compiler\stencil.js
Build: 1705946070
Stencil: 4.11.0
TypeScript: 5.3.3
Rollup: 2.56.3
Parse5: 7.1.2
Terser: 5.27.0
Steps to Reproduce
Create a new stencil project and simply use the default components already set by default.
Create a type in the component.tsx file, for example : export type ButtonColors = 'primary-500' | 'secondary-500';
Use this type on a @Prop : @Prop() color: ButtonColors = 'primary-500';
Now, everytime you need this prop on your component in stencil env it will work perfectly
But if you export your components in a npm package and import them in angular 16 you can't get the types.
For example :
app.component.html
I have nothing in color, I would like to get the possibility to choose between primary and secondary.
I already followed the documentation which says to create a interfaces.d.ts file in the root
https://stenciljs.com/docs/angular#why-arent-my-custom-interfaces-exported-from-within-the-indexdts-file
Code Reproduction URL
Should I create a reproduction code in stencil or angular ? The problem is between the two, tell me what is better for you and I"ll give it to you
Additional Information
No response
- Dominant language
- TypeScript
- Stars
- 13.1k
- Forks
- 855
- Avg merge
- 4h 7m
- Merged PRs (30d)
- 44
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from stenciljs/core
-
Stencil v5
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Stencil v5
Difficulty 4/5 3-5 days Newbie friendliness 55/100
-
Bug: Validated Stencil v5
Difficulty 4/5 3-5 days Newbie friendliness 48/100
-
Feature: Want this? Upvote it!
Difficulty 5/5 Over a week Newbie friendliness 25/100
-
Feature: Want this? Upvote it!
Difficulty 4/5 3-5 days Newbie friendliness 48/100
Similar issues
-
clawsweeper:fix-shape-clear clawsweeper:queueable-fix clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster no-stale P3
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficulty 1/5 Under an hour Newbie friendliness 76/100
-
code-quality refactoring
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
github/gh-aw-firewall#8816 ·
-
integration:quickjs org:external priority:backlog topic:code-interpreter topic:middleware type:feature
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
langchain-ai/deepagents#6450 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
vercel/react-tweet#225 ·