Widget Creation/Install confusion

864
3
Jump to solution
12-08-2014 08:35 AM
DouglasGennetten
New Contributor III

I've successfully created and installed several widgets but still remain confused as to exactly what is needed for a new widget.  Sometimes, I see a newly created widget show up multiple times in WABs widget chooser. What causes that?

In the help file, creating the new "MyWidge" in stemapp/widgest/samplewidgests requires editing config-demo.json to test. This is automated normally, right? 

Just now, when creating a new widget from CustomWidgetTemplate folder, and placing it up on level in \widgets\, I see it recognized in the server log, but it isn't showing up at all in the WAB widget chooser. What can cause this? It's worked before.

...wishing the documentation were more complete...

0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus

Douglas,

  I am not 100% sure what is causing

I see a newly created widget show up multiple times in WABs widget chooser

Some things to check is that the folder name for your widget is unique and that the manifest.json file has been updated. The name property in the manifest.json should be unique and Boolean properties should not be wrapped in quotes.

In the help file, creating the new "MyWidget" in stemapp/widgets/samplewidgets requires editing config-demo.json to test. This is automated normally, right?

Absolutely. The steps in the help doc are just having you work with an existing config.json instead of creating a new app. If you were to create a new app the new widget would be listed in the UI and added to the config.json automatically when it is chosen.

Just now, when creating a new widget from CustomWidgetTemplate folder, and placing it up on level in \widgets\, I see it recognized in the server log, but it isn't showing up at all in the WAB widget chooser. What can cause this? It's worked before.

There is a error in the manifest.json file for the CustomWidgetTemplate. The 2D and 3D properties have boolean values that are wrapped in qoutes. Remove the qoutes from around the true/false values and it will work fine.

...wishing the documentation were more complete...

I am sure it will get better when it is out of Beta.

View solution in original post

0 Kudos
3 Replies
RobertScheitlin__GISP
MVP Emeritus

Douglas,

  I am not 100% sure what is causing

I see a newly created widget show up multiple times in WABs widget chooser

Some things to check is that the folder name for your widget is unique and that the manifest.json file has been updated. The name property in the manifest.json should be unique and Boolean properties should not be wrapped in quotes.

In the help file, creating the new "MyWidget" in stemapp/widgets/samplewidgets requires editing config-demo.json to test. This is automated normally, right?

Absolutely. The steps in the help doc are just having you work with an existing config.json instead of creating a new app. If you were to create a new app the new widget would be listed in the UI and added to the config.json automatically when it is chosen.

Just now, when creating a new widget from CustomWidgetTemplate folder, and placing it up on level in \widgets\, I see it recognized in the server log, but it isn't showing up at all in the WAB widget chooser. What can cause this? It's worked before.

There is a error in the manifest.json file for the CustomWidgetTemplate. The 2D and 3D properties have boolean values that are wrapped in qoutes. Remove the qoutes from around the true/false values and it will work fine.

...wishing the documentation were more complete...

I am sure it will get better when it is out of Beta.

0 Kudos
DouglasGennetten
New Contributor III

Yes, the folder name is unique.

Once, I think I may have caused this, and other havoc,  by changing "name" in manifest.json from "MyWidget" to "My Widget".

0 Kudos
DouglasGennetten
New Contributor III

There is a error in the manifest.json file for the CustomWidgetTemplate. The 2D and 3D properties have boolean values that are wrapped in qoutes. Remove the qoutes from around the true/false values and it will work fine.

That was it.  Thanks.

0 Kudos