0

The requirement is to use of the node modules in my controller file of a UI5 app. I've installed the module and it resides in my npm_module folder. Based on the below blog, I've added some configurations in my ui5.yaml, yet I get the error pasted below.

Can anyone help me in this regard?

Blog Referred: https://blogs.sap.com/2020/07/30/project-shims-using-npm-modules-with-ui5/

Code screenshot enter image description here

Error: failed to load 'thirdparty/aws-sdk.js' from resources/thirdparty/aws-sdk.js: script load error

05_pingpong
  • 77
  • 1
  • 2
  • 13
  • Did you add aws-sdk to your ui5dependencies in the package.json? – Marc Jan 13 '22 at 07:53
  • yes, it is present in package.json as well. ` "ui5": { "dependencies": [ "@sap/ux-ui5-tooling", "@sap/ui5-builder-webide-extension", "ui5-task-zipper", "mbt", "aws-sdk" ] }, "dependencies": { "aws-sdk": "^2.1055.0", "ui5-tooling-modules": "^0.1.1" } }` – 05_pingpong Jan 13 '22 at 09:27

1 Answers1

0

Update: The issue was the path mentioned in the controller. I changed it to refer to the dist folder where the actual aws-sdk.js existed. And it resolved the error.

05_pingpong
  • 77
  • 1
  • 2
  • 13