Open davidjgonzalez opened 3 years ago
Are there any updates to this? Our team needs to extend the data layer as well, but we can't find any documentation on how to do it, but rather just copy-down and "work arounds" as @davidjgonzalez also mentioned.
Feature Request
Is your feature request related to a problem? Please describe.
Can you please document with code samples how to properly extend the provided data layer objects (for any
.asXXX(..)
) with custom data key/values?I don't see this documented in this Git repo or on Adobe Documentation. The solution here: https://experienceleague.adobe.com/docs/experience-manager-learn/sites/integrations/adobe-client-data-layer/data-layer-customize.html?lang=en#sling-model is copy-down code, and "works around" the provided Java APIs (and looks like has the opportunity to lose the OOTB data points)
These docs https://experienceleague.adobe.com/docs/experience-manager-core-components/using/developing/data-layer/extending.html?lang=en#developing imply we can provide a custom
XxxData
object, but I'm not clear how that would actually work given the public APIs.Describe the solution you'd like
Add documentation on how to add custom data layer key/values to the resulting JSON object to the README: https://github.com/adobe/aem-core-wcm-components/blob/master/DATA_LAYER_INTEGRATION.md
Documentation
Something like the following code snippet, but show how/which methods to call and pass in custom data.