In outsystem, I want to download a shape file from the geojson data. I m referring shpwrite.js library (https://github.com/mapbox/shp-write). I download the mentioned lib and included in the script folder. Also referenced, the library in the screen--> required scripts. when I publish and open in browser, I always ends up on this error,
Module name "stream" has not been loaded yet for context: _. Use require([])
Any help would be appreciated. if any other way of creating and downloading, please specify.
Note: When I use it outside outsystem in an html page, this works well. for rerference, I am herewith attaching the oml file.
Hi,
I believe for what you wrote that you already know this, but I will let you here anyway if you want to double check:
https://success.outsystems.com/documentation/11/extensibility_and_integration/javascript/extend_your_mobile_and_reactive_apps_using_javascript/use_javascript_code_from_an_external_library/
I found a topic similiar with yours that have content that can help you:
https://www.outsystems.com/forums/discussion/55258/load-external-js-in-outsystems-reactive-web-app/#Post270147
In that post they find a diferent solution for what it seems to be a similar scenario.
Hope this can help you.
Best regards,
Ricardo
This is fixed by following,
1. Open javascript
2. Comment out this line of code
//module.exports = require("stream");
Worked !!