Expand my Community achievements bar.

Learn about Edge Delivery Services in upcoming GEM session

Calling Javascript USE API outside of sightly?

Avatar

Level 3

I'm just wondering , Can we call Java Script Use API outside of Sightly? More preciously like calling it from java script function, so it can update some node properties etc.

1 Reply

Avatar

Administrator

Hi

As mentioned, the best practice is to modify anything at JCR level, create a service/Component.

The Sightly JavaScript Use-API enables a Sightly file to access helper code written in JavaScript. This allows all complex business logic to be encapsulated in the JavaScript code, while the Sightly code deals only with direct markup production.

Reference good article to read is :- http://blogs.adobe.com/experiencedelivers/experience-management/sightly-intro-part-4/

I hope this would be helpful to you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni