Get first element of a bean list in sightly : AEM 6.2 | Community
Skip to main content
cquser1
Level 7
February 24, 2017

Get first element of a bean list in sightly : AEM 6.2

  • February 24, 2017
  • 0 replies
  • 969 views

Hi All,

Suppose I have a bean class Sample.java, which in turn has one attribute private List<Image> images. The Image.java has private String url. I want to read only the first url property of the list in my sightly file.

Any thoughts/pointers/reference code on how to do this will be really helpful.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.