In alfresco share, having a page, is there any way to figure out which .js file is associated with it ?
2 Answers
In Alfresco Share a Page aggregates a whole lot of Surf components, each of which have typically a Javascript controller. There's a great tool to debug your Share pages which is called SurfBug. It will tell you the associated controllers and view for all the Surf components on a page.

- 13,414
- 1
- 48
- 67
Do you mean javascript file for java script controller or for event trigger java script file?
- For java script controller,
You can see directly using SurfBug for viewing surf components files according to previous answer. For example, workflow-list component in workflow listing page, workflow-list.get.js is javascript controller file.
- For event trigger javascript file,
Usually this file is indicated by XXXXX.head.ftl file. For example, workflow-list.get.head.ftl file
<#include "../component.head.inc">
<!-- Common Workflow Actions -->
<@script type="text/javascript" src="${page.url.context}/res/components/workflow/workflow-actions.js"></@script>
<!-- Workflow List -->
<@link rel="stylesheet" type="text/css" href="${page.url.context}/res/components/workflow/workflow-list.css" />
<@script type="text/javascript" src="${page.url.context}/res/components/workflow/workflow-list.js"></@script>
In this example, workflow-list.js is the javascript event handler file.

- 5,840
- 4
- 32
- 54