Hello,
I am builder a custom widget that will be similar as the coordinate widget.
I am still a seed in the ground with ExB widget.
Everything is working except for the marker.
I want to be able to add a marker like this when I click on a map I don't know how to make the marker appear. I took inspiration from the coordinate widget. I copied this function into my code to start but...
Bu when I reload I get this (failed to load)
I am stuck there... any creation of any object will give me that problem ( const xyz = new Whatever() )
the function is not event called anywhere in my code at this point.
I coded my widget base on a function model (not a class). But I think the coordinate widget is also a function...
Any idea ?
Thanks
Sylvain
Solved! Go to Solution.
I need to add "dependency": "jimu-arcgis" in the manifest
I need to add "dependency": "jimu-arcgis" in the manifest
@sylvainhotte1 Would you be willing to share your widget?
@Brian_McLeerYes no problem. I still have a few things to adjust then I will send it to you. It should be done next week.
Sylvain
Hello @Brian_McLeer here's the small widget I made.
The widget is called xyurl
The setting needs a map, the text for the button a url ({x}{y} will be replaced with the actual coordinate one you click on the map) and the color of the pin on the map
in runtime
(1) click the cross and the the map (the pin will appear)
(2) the you can click the button
(3) click the trash can to delete the pin
This is my first widget, so it may not be perfect.
Hope it help
regards,
Sylvain
Thank you @sylvainhotte1, I appreciate you being open to sharing it.