$(document).on("foundation-contentloaded") dialog event is not working as expected in AEMaaCS

Avatar

Avatar
Boost 25
Level 3
ibishika
Level 3

Likes

30 likes

Total Posts

29 posts

Correct reply

3 solutions
Top badges earned
Boost 25
Affirm 3
Boost 10
Boost 5
Give Back
View profile

Avatar
Boost 25
Level 3
ibishika
Level 3

Likes

30 likes

Total Posts

29 posts

Correct reply

3 solutions
Top badges earned
Boost 25
Affirm 3
Boost 10
Boost 5
Give Back
View profile
ibishika
Level 3

27-04-2021

I have used the below code to detect a dialog load event for previous versions of AEM (I think AEM 6.3). Currently I am using AEMaaCS and when I use the same, I notice that the control is never going inside the below code:
$(document).on("foundation-contentloaded", function (e) {
});

Please share if there is any solution or any other way of doing this.

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Applaud 25
Level 10
asutosh_jena
Level 10

Likes

593 likes

Total Posts

705 posts

Correct reply

207 solutions
Top badges earned
Applaud 25
Give Back 100
Boost 500
Affirm 100
Ignite 1
View profile

Avatar
Applaud 25
Level 10
asutosh_jena
Level 10

Likes

593 likes

Total Posts

705 posts

Correct reply

207 solutions
Top badges earned
Applaud 25
Give Back 100
Boost 500
Affirm 100
Ignite 1
View profile
asutosh_jena
Level 10

27-04-2021

Hi @ibishika 

 

Please use with below code:

 

(function ($, $document) {
$document.on("dialog-ready", function () {
// code will go here
console.log("dialog ready now!!!");
});
})($, $(document));

This will be executed when the dialog is loaded.

 

Thanks! 

Answers (0)