Forums de discussion

Need help to understand two lines of AUI function.

Riddhi Shah, modifié il y a 11 années.

Need help to understand two lines of AUI function.

New Member Publications: 24 Date d'inscription: 06/03/12 Publications récentes
HI All,

I want to know what does below AUI function does. Its important for me to know this as i want to remove this code especially the lines related to "Navigation" for resolving some other defect in my code. But i do not have enough knowledge on themes or AUI.

Below code is written in main.js in theme.

AUI().ready(
	'liferay-hudcrumbs', 'liferay-navigation-interaction',
	function(A) {
		var navigation = A.one('#navigation');

		if (navigation) {
			navigation.plug(Liferay.NavigationInteraction);
		}

		var siteBreadcrumbs = A.one('.site-breadcrumbs');

		if (siteBreadcrumbs) {
			siteBreadcrumbs.plug(A.Hudcrumbs);
		}
	}
);


I want to know what implication it will have if i remove the code of Navigation. There is a div with id "navigation" in portal_normal.vm in my custom code.