Best practice - javascript API components VS Java API components | Community
Skip to main content
New Participant
December 6, 2015
Solved

Best practice - javascript API components VS Java API components

  • December 6, 2015
  • 2 replies
  • 1312 views

Hi i've come across some discussions about best practice recently and one of the points raised was around usage of java API to build components insted of javascript API. The arguments were:
1 - Javascript will be converted to java classes anyway
2 - Use Java to keep consistency across platform (other components are java based)

Said that, what technology the group suggest (best practice aka recommended) to develop components? If java based components are best practice, what is the aim of javascript technology to develop components then? 

Please note the aim of this question is not to fire a discussion about javascript vs java.

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

Hi 

To know best practices for AEM components :-

Link:- https://helpx.adobe.com/experience-manager/using/best-practices-cq-component-design.html

Link:- http://antonyh.co.uk/2012/01/cq5-best-practices-for-component-development-html/

 

Apart from the above mentioned reference links, please find a article which might help you better understand the concepts :-

Link:- http://www.aemcq5tutorials.com/tutorials/sightly-new-features-vs-jsp-aem/

Advantages of using Sightly 

Below advantages of using Sightly make you to code sightly easier and faster : 

Lightweight – No dependencies, fast and lean. 
Secure – Automatic contextual XSS protection and URL externalization. 
Code-less – Enforce separation of concerns between logic and markup. 
Powerful – Straight-forward API for logic, allowing to do virtually anything. 
Intuitive – Clear, simple & restricted feature set

 

Difference between Sightly vs JSP 

Sightly Offers below advantages over JSP for better development in AEM : 
Protection against cross-side scripting injection. 
Easily development of AEM Projects by front-end developers. 
Flexible and powerful templating and logic binding features. 
Strong connection to Sling use case. Slightly only Supports HTML5. 
Using sightly components development becomes a part of Web Developer instead of a java developer.
Need to write less code in Sightly thus productivity increases. 
Wider range of implicit objects as compared to JSP.

 

I hope this would help you.

Thanks and Regards

Kautuk Sahni

2 replies

kautuk_sahni
kautuk_sahniAccepted solution
Employee
December 7, 2015

Hi 

To know best practices for AEM components :-

Link:- https://helpx.adobe.com/experience-manager/using/best-practices-cq-component-design.html

Link:- http://antonyh.co.uk/2012/01/cq5-best-practices-for-component-development-html/

 

Apart from the above mentioned reference links, please find a article which might help you better understand the concepts :-

Link:- http://www.aemcq5tutorials.com/tutorials/sightly-new-features-vs-jsp-aem/

Advantages of using Sightly 

Below advantages of using Sightly make you to code sightly easier and faster : 

Lightweight – No dependencies, fast and lean. 
Secure – Automatic contextual XSS protection and URL externalization. 
Code-less – Enforce separation of concerns between logic and markup. 
Powerful – Straight-forward API for logic, allowing to do virtually anything. 
Intuitive – Clear, simple & restricted feature set

 

Difference between Sightly vs JSP 

Sightly Offers below advantages over JSP for better development in AEM : 
Protection against cross-side scripting injection. 
Easily development of AEM Projects by front-end developers. 
Flexible and powerful templating and logic binding features. 
Strong connection to Sling use case. Slightly only Supports HTML5. 
Using sightly components development becomes a part of Web Developer instead of a java developer.
Need to write less code in Sightly thus productivity increases. 
Wider range of implicit objects as compared to JSP.

 

I hope this would help you.

Thanks and Regards

Kautuk Sahni

Kautuk Sahni
GK-007
New Participant
December 7, 2015

Refer below link this might help you.

http://www.slideshare.net/GabrielWalt/aem-bestpractices

Kishore