You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
The bug originates from trying to use the @sap-cloud-sdk in a Typescript SAPUI5 Application. After the installation of the module, following this tutorial: Link, I am using ui5-tooling-modules to convert the package to Typescript. Now, when starting the application with ui5 build --clean-dest --config ui5.yaml, I get the depicted error: types" is not exported by "polyfill-node.util.js", imported by "node_modules/node-fetch/src/body.js
Import any part of @sap-cloud-sdk/http-client into a .ts-file. For example: import { executeHttpRequest } from "@sap-cloud-sdk/http-client")
Start the application via ui5 build --clean-dest --config ui5.yaml
Expected behavior
The module ui5-tooling-modules-middleware should convert the package using ES modules or commonjs. The application start without errors.
Screenshots
Desktop:
Not relevant
Smartphone:
Not relevant
The text was updated successfully, but these errors were encountered:
The biggest issue with the Cloud SDK is that is works somehow in the browser but it seams that it wasn't designed from scratch for that use case and therefore using a generic bundling step is cumbersome. In their docu they describe the webpack configuration to bundle it but I wonder if it still works with Angular / React. Anyways, this looks like a challenge. I'll try to take a look...
For UI5 they got a ticket beginning of last year but they gave up in looking into supporting UI5: SAP/cloud-sdk-js#704 😢
In favor of your topic, I'm closing the old issue because the topic of the cloud-sdk was not the original issue if it...
petermuessig
changed the title
"types" is not exported by "polyfill-node.util.js", imported by "node_modules/node-fetch/src/body.js"
[ui5-tooling-modules] "types" is not exported by "polyfill-node.util.js", imported by "node_modules/node-fetch/src/body.js"
Aug 21, 2024
Description
The bug originates from trying to use the
@sap-cloud-sdk
in a Typescript SAPUI5 Application. After the installation of the module, following this tutorial: Link, I am usingui5-tooling-modules
to convert the package to Typescript. Now, when starting the application withui5 build --clean-dest --config ui5.yaml
, I get the depicted error:types" is not exported by "polyfill-node.util.js", imported by "node_modules/node-fetch/src/body.js
Steps to reproduce the behavior:
npm install ui5-tooling-modules --save-dev
npm install --save-dev @sap-cloud-sdk/http-client
import { executeHttpRequest } from "@sap-cloud-sdk/http-client")
ui5 build --clean-dest --config ui5.yaml
Expected behavior
The module ui5-tooling-modules-middleware should convert the package using ES modules or commonjs. The application start without errors.
Screenshots
Desktop:
Smartphone:
The text was updated successfully, but these errors were encountered: