Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

error in widgets.js when trying to edit a component - AEM 6.1

Avatar

Avatar
Validate 10
Level 3
sathya_prakasha
Level 3

Likes

22 likes

Total Posts

98 posts

Correct Reply

2 solutions
Top badges earned
Validate 10
Validate 1
Ignite 5
Ignite 3
Ignite 10
View profile

Avatar
Validate 10
Level 3
sathya_prakasha
Level 3

Likes

22 likes

Total Posts

98 posts

Correct Reply

2 solutions
Top badges earned
Validate 10
Validate 1
Ignite 5
Ignite 3
Ignite 10
View profile
sathya_prakasha
Level 3

22-09-2019

The issue occurs when I'm adding extra drop-down in the dialog fieldset. 

/apps/MySite/components/HelloWorld/dialog.overlay.infinity.json - showing as an array instead of JSON

The problem appears because the snippet variable is not an object but an array.

This type of response is not handled by the widget.js and getting failed at below condition.

if (snippet.xtype.indexOf("dialog") != -1 || snippet.xtype.indexOf("wizard") != -1) {

dialogConfig = snippet;

            }

Could anyone share your insights on this??

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Contributor
Employee
hamidk92094312
Employee

Likes

101 likes

Total Posts

240 posts

Correct Reply

38 solutions
Top badges earned
Contributor
Shape 1
Ignite 1
Give Back 50
Give Back 5
View profile

Avatar
Contributor
Employee
hamidk92094312
Employee

Likes

101 likes

Total Posts

240 posts

Correct Reply

38 solutions
Top badges earned
Contributor
Shape 1
Ignite 1
Give Back 50
Give Back 5
View profile
hamidk92094312
Employee

23-09-2019

Ref: The problem appears because the snippet variable is not an object but an array.

It seems to be a case of calling a method of some object X to object Y while they don't share the same method/properties i.e. An array object doesn't have a indexOf method 

Answers (0)