Expand my Community achievements bar.

SOLVED

json exporter - Filter allowed components aem 6.5

Avatar

Level 5

Hi Friends ,

 

Is there any ootb configuration available to filter the component exporter.

 

For example : http://localhost:4502/content/we-retail/us/en/men.model.json

 

it showing allowedComponents gridClassNames ,columnCount etc ..  I want to expose only essential items to react

1 Accepted Solution

Avatar

Correct answer by
Level 4
8 Replies

Avatar

Level 6

@AEMLearner-1989 

 

You want to export particular complement or  entire page which one you need to export ??

 

Regards

Manikantha R

Avatar

Level 5

Entire page but dnt wanna expose the unwanted elements like allowedcompoments to other applications.

Avatar

Level 4

Hi @AEMLearner-1989 

their is an annotation called @JsonIgnore which is used to hide the unwanted elements in your sling model.

add this annotation to the elements which you don't want to expose.

thanks.

Avatar

Level 1

i got solution..Thank you

 

Avatar

Level 6

How you achieved this ??

Avatar

Correct answer by
Level 4

Avatar

Level 7

Hi @AEMLearner-1989,

 

You can use Jackson Annotation @JsonIgnore for that. Please find the detailed article regarding this.

 

https://experienceleague.adobe.com/docs/experience-manager-64/developing/components/json-exporter-co...

 

http://www.sgaemsolutions.com/2017/06/sling-model-exporter-in-aem-63.html

 

 

Regards,

Santosh

Avatar

Level 2

Hello, 

 

We do have similar requirement to exclude the allowedComponents from the jackson exporter, but we are not overlaying ResponsiveGrid class ( wcm/foundation/components/responsivegrid ) to use jsonIgnore annotation, Can you help or elaborate how is it achieved at your end.

 

Thanks,

-Krishna.