on 03-15-2021 6:21 AM
how can I use more than 1 manifest.json files for UI5 application,
and what is the advantage of using more manifest.json files in application.
Refer to this link in the SAPUI5 documentation: Descriptor for Applications, Components, and Libraries.
There we can read, among other things:
It says nothing about a possibility to split this into several files. And I don't see the use as it would make no sense describing the app differently in different places either. So there is one manifest.json app descriptor per app.
Are you possibly thinking about Descriptor for Libraries or Descriptor for Components (Inside Libraries)? But you would still only have one descriptor per each object...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I always just use one manifest.json per application or library. Why would you consider using more than one?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Idea is to use different look and feel for cases of error. Lets say one manifest is for representation for KPI (in % and some text) and it can use header of Integration Card and another manifest is to use error handling (which might be icon and some text), which can use body of integration card. But I don't want header and body in the same manifest. Any idea how to do that?
you can have multiple html entry points each with own data version.
you could pass componentData through your index.html.
<body role="application" data-sap-ui-component
data-name="your.component.name"
data-settings='{"id": "one",
"componentData": {
"foo": "bar"
}}'>
in index2.html you pass different componentData.
<body role="application" data-sap-ui-component
data-name="your.component.name"
data-settings='{"id": "two",
"componentData": {
"foo": "pub"
}}'>
in your component override init & process your ComponentData
sap.ui.define([
"sap/ui/core/UIComponent"
], function(jQuery, UIComponent) {
"use strict";
var YourComponent = UIComponent.extend("your.component.name", {
metadata: {
manifest: "json",
library: "your.library.name",
version: "1.0",
}
});
YourComponent.prototype.init = function() {
// call the base component's init function
UIComponent.prototype.init.apply(this, arguments);
alert(this.getComponentData()?.foo == "pub" ? "beer" : "gin");
};
return YourComponent;
});
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
what function you are trying to achieve with multiple manifest?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
search for integration cards sapui5
User | Count |
---|---|
77 | |
8 | |
7 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.