adobe / spectrum-web-components

Spectrum Web Components
https://opensource.adobe.com/spectrum-web-components/
Apache License 2.0
1.24k stars 200 forks source link

Can't import components into an Angular 17 project. #3995

Open bzupancic opened 7 months ago

bzupancic commented 7 months ago

Code of conduct

Description of issue

When attempting to import a component into my Angular project via import { Switch } from '@spectrum-web-components/switch' I receive the error message:

This likely means that the library (@spectrum-web-components/bundle) which declares Switch is not compatible with Angular Ivy. Check if a newer version of the library is available, and update if so. Also consider checking with the library's authors to see if the library is expected to be compatible with Ivy.

I can use <script src="https://jspm.dev/@spectrum-web-components/switch.js" type="module" async></script> but there has to be a better way...

Westbrook commented 7 months ago

Does this process still benefit from https://angular.io/api/core/CUSTOM_ELEMENTS_SCHEMA?

Would you be able to share more info about what it means to be "compatible with Angular Ivy."?