storybookjs / aem

Adobe Experience Manager Storybook app with events, knobs, docs, addons, and more
https://storybook-aem.netlify.com/
MIT License
33 stars 24 forks source link

Support 3rd party aem component libraries #45

Closed CodeByAlex closed 4 years ago

CodeByAlex commented 4 years ago

Right now the htl engine works with custom components but not proxy components. We need to provide this capability so that people can use the core components

CodeByAlex commented 4 years ago

@tripodsan from the Discord chat:

I think it should work like this:

then a user you would:

and then just use the normal sling:resourceSuperType in his custom component. and import / extends the model if he needs eg:

import Text from `aem-core-components.storified`.models;

class MyText extends Text {
}
CodeByAlex commented 4 years ago

The above however only supports a single library type - it would be great to support any 3rd party library...thinking of a solution for that. We can easily get the css and html for a component by making a one time call to a live aem instance using our cli tool ( we would have to add the capability) - but how would we get any information about the java models (assuming the libs are written using java models - if they are using javascript, it becomes very easy to include them)

CodeByAlex commented 4 years ago

We now have a path forward to achieve this