Reputation: 460
How to convert an ember addon to web component?
https://github.com/BBVAEngineering/ember-cli-web-components This plugin is not working, I am getting, defineCustomElements is not defined error.
Then I found glimmer can create web components. With glimmer, I need to convert ember addon to glimmer, then create web component (which is time consuming). Also I am not able to pass arrays and objects to web component created using glimmer (can only pass strings using atrributes) and the web component is not using shadow dom (which can cause problems with styling).
Ember octane is using glimmer component, but cannot find in its documentation if it can be converted to web component
So what is currently the best way to convert ember addon to web component?
Upvotes: 1
Views: 273
Reputation: 803
Did you import the defineCustomElements
in the app.js.
You can refer https://github.com/BBVAEngineering/ember-cli-web-components/blob/master/tests/dummy/app/app.js this file and especially this line (https://github.com/BBVAEngineering/ember-cli-web-components/blob/master/tests/dummy/app/app.js#L5).
Upvotes: 0