Description
In a bundle file (no matter whether it's a Component-preload.js
or a library-preload.js
file) calls to the bundle-only APIs sap.ui.predefine
or sap.ui.require.preload
are reported as use of a disallowed global.
While this might be limited to framework code, it might be fixable in a robust way. UI5 tooling adds comments to bundles that would allow to identify them
//@ui5-bundle sap/f/library-preload.js
/*!
* OpenUI5
* (c) Copyright 2009-2024 SAP SE ...
@codeworrior added those comments to the manually created preloads in sap.ui.core
, just in case we want to use them as markers.
As the two APIs in question are not documented as public APIs (only restricted, AFAIK), they either might have to be added to the overlay or have to be listed in the linter's source (similar to the other allowed globals).
Note: This issue is assumed to be specific to framework code only. It's not likely that application code or reuse libs create (non-empty) bundles as part of the sources.
Context
- UI5 linter version: 0.2.2
- Node.js Version: v20.11.1
- npm Version: 10.2.4
- OS/Platform: macOS 14.4.1