Show TOC

Bootstrapping: Loading and Initializing SAPUI5 in HTML PagesLocate this document in the navigation structure

SAPUI5 provides several bootstrap files for different use cases.

The following table gives an overview of the most important resources and the respective use cases. The resource names refer to the resources/ folder in the SAPUI5 installation. The actual base URL depends on your platform and administrative setup.

Resource Description
sap-ui-core.js

This is the standard bootstrap file. It already contains jQuery, jquery-ui-position and only the minimum required parts of the core library (sap.ui.core). Required files are loaded dynamically using XMLHttpRequest (XHR).

For more information, see Standard Variant for Bootstrapping.

sap-ui-core-nojQuery.js

You use this bootstrap file for applications with their own jQuery version. It also contains the minimum required parts of the core library, but not jQuery and jquery-ui-position.

For more information, see noJQuery Variant for Bootstrapping.

sap-ui-core-all.js

This bootstrap file contains almost all resources of the sap.ui.core library. Only a few duplicates, such as multiple jQuery versions, testing resources, and so on, are omitted. If you use this file for bootstrapping, the *-all.js file is also loaded for all other libraries. This reduces the number of JavaScript requests to the number of libraries (typically 1..4).

Note To ensure proper encapsulation, the *-all.js files will be renamed in future versions of SAPUI5. The sap-ui-core-all.js file remains as is, but for the files for other libraries a name relative to the library will be used, for example sap/ui/commons/library-all.js. Applications must not address these files directly as SAPUI5 runtime loads them. Only sap-ui-core-all.js can be directly referenced in the bootstrap tag.

For more information, see All-in-one per Library Variant for Bootstrapping.

sap/ui/core/library-preload.js

This bootstrap file is similar to the sap-ui-core-all.js file, but the modules are parsed and executed only on demand, and not immediately.

Caution An application must not reference this file. If the configuration option is set to preload, SAPUI5 automatically loads the file.

For more information, see Preload Variant for Bootstrapping.

sap-ui-core-lean.js

This bootstrap file is similar to the sap-ui-core.js file, but in this use case only the jQuery and one SAPUI5 file are loaded immediately and the other files are loaded dynamically.

Note

This use case is usually not used and may be removed in future.

sap-ui5.js

This bootstrap file contains all JavaScript modules from the sap.ui.core, sap.ui.commons, sap.ui.table and sap.ui.ux3 libraries. If you use this file for bootstrapping, you only need one single request, but the loading time may be longer as the loading time for other use cases. Another drawback of this use case is the fixed set of libraries.

This file is only available on platforms based on the sapui5.war or sapui5-static.zip artifacts. The OSGi/Eclipse versions (com.sap.ui5.core.jar), for example, do not contain this file.

For more information, see sap-ui5 Variant for Bootstrapping.

sap-ui-custom*.js

This bootstrap file is reserved for custom merged files created by the application.

Note The proposed naming scheme for these files needs to be adapted in future versions for the same encapsulation reasons as mentioned above.