SAP / ui5-tooling

An open and modular toolchain to develop state of the art applications based on the UI5 framework
https://sap.github.io/ui5-tooling
Apache License 2.0
465 stars 69 forks source link

Dependency bundling ignores mvc factory functions #382

Open RandomByte opened 5 years ago

RandomByte commented 5 years ago

Expected Behavior

MVC factory APIs like sap.ui.fragment should be identified as dependency declarations.

Current Behavior

Resources referenced by MVC factories are not processed as bundle dependencies.

Steps to reproduce the issue

  1. Setup openui5-sample-app
  2. Add sap.ui.layout dependency for technical information dialog: npm install @openui5/sap.ui.layout
  3. Execute ui5 build self-contained --all
  4. Serve dist directory
  5. Open technical information dialog by pressing CTRL + SHIFT + ALT + P
  6. Observe in the network trace that single sap.ui.layout controls are being loaded.
    ➡️ This indicates that they are not part of the self contained bundle

Related code: https://github.com/SAP/openui5/blob/9974c1e7f9179397745d896df72cf2d1d773f325/src/sap.ui.core/src/sap/ui/core/support/techinfo/TechnicalInfo.js#L79

CC: @codeworrior

Also see https://github.com/SAP/ui5-tooling/issues/68

Affected components

flovogt commented 9 months ago

Still reproducible also with UI5 Tooling V3