
I now learning the example in Create a FeatureLayer from a shapefile, but are there preferred documents/links or code examples to learn from?
After my widget javascript code has the path to the ziped shapefile in the PC, since it's my first time of doing such thing - I will appreciate to get links/code examples how to import it into the Scene. Next code snippet displays an explorer download dialog to the user, but how can I set a promise to know WHEN the user finished? either by cancelling or approving the download, and what is the final path and name of the downloaded zip, since the user can change things in the explorer download dialog? and since I don't know how to "connect" to the explorer download dialog box?.
Is there some "magic" javascript code to download it by my web application without displaying explorer download dialog to the user? And that my javascript will know the downloaded path? Perhaps by " fetch" (which I am not familiar to)? If yes, how?.
Can I import the url directly to my scene?.
Now I want to import the zipped shapefile into my 3D scene, with minimum manual user operations, but mainly by the javascript code.
I adapted the code in FME Server Playground - Upload File In Session into my ESRI Web AppBuilder custom-widget javascript code, and after uploading input file to my FME cloud and running the cloud workspace, all by javascript alone, the returned json has the url of the result zipped shapefile.