Closed
Description
Prequisites
- 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.
Ionic Framework Version
- v4.xv5.xv6.x
Current Behavior
node_modules/ionicons/dist/types/components.d.ts:66:15 - error TS2320: Interface 'HTMLIonIconElement' cannot simultaneously extend types 'IonIcon' and 'HTMLStencilElement'.
Named property 'ariaLabel' of types 'IonIcon' and 'HTMLStencilElement' are not identical.
66 interface HTMLIonIconElement extends Components.IonIcon, HTMLStencilElement {
~~~~~~~~~~~~~~~~~~
npm run build (using vite) results in the above error
Expected Behavior
npm run build with no errors
Steps to Reproduce
running "npm run build" results in multiple of the above error messages, i found an issue regarding this over a year ago, but it was closed with no explanation on how the bug occurred.
I am using @ionic/vue V6 with vite
Please let me know if any further details are required
Code Reproduction URL
https://github.com/Ripwords/astro-calc
Ionic Info
Additional Information
Similar issue in #20208
Update
I was able to track down the issue in ionicons here. It seems to be a typescript version error, however the ionicons repo doesn't seem to be as active and I would rate this issue quite high since typescript is getting more and more popular
Activity
[-]bug: [/-][+]bug: @ionic/vue v6 can't run build with vite[/+]liamdebeasi commentedon Oct 4, 2021
Thanks for the issue. If you add
"skipLibCheck": true
to yourtsconfig.json
file does that fix the issue? We recommend having this set (our starter apps have it set automatically). I also noticed runningnpm run build
causes it to complain about some TypeScript files too, and settingskipLibCheck
resolved both issues for me.Ripwords commentedon Oct 5, 2021
Thanks, I tested it and it's working as expected now. Maybe this could be mentioned in the docs for those who are adding ionic as a library instead of using the starter apps. Although that might be the minority of the users.
liamdebeasi commentedon Oct 5, 2021
Glad it works. Yes, I agree this should be mentioned in the docs. I am going to close this issue for now, but we plan on having more docs on getting Ionic setup with Vite when Ionic 6 ships (this is being tracked internally).
ionitron-bot commentedon Nov 4, 2021
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.