Skip to Content

Manifest.json settings in Component.js file in UI5

Hi all,

we have a SAP note to be followed as part of remediation to upgrade of SAP_UI component

"2500102 - My inbox Console Error: Cannot get UI2ShellService - Error: Service UI2ShellService not declared! cross.fnd.fiori.inbox.Component"

This note says that to maintain below setting

" add a reference to ShellUIService inside the "sap.ui5" block in the manifest.json file in your customized application like this: "services":{ "ShellUIService": { "factoryName": "sap.ushell.ui5service.ShellUIService" }"

but our extended app doesnot support Manifiest.json file .

How can we maintain above setting in Component.js?

Thanks

Prasad

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Feb 23 at 04:28 AM

    Ideally these settings should be maintained in manifest.json file and the file should be referenced in your component.js file.

    For Example:

    sap.ui.core.UIComponent.extend("yourComponent.Component",

    {

    metadata: { manifest: "json" },

    init() {}

    });

    But if you want to maintain it in component.js file , you will need to declare the details in the metadata tag.

    metadata: {

    services :{ ShellUIService:

    { factoryName: "sap.ushell.ui5service.ShellUIService" }

    }

    }

    Add comment
    10|10000 characters needed characters exceeded

  • Feb 22 at 08:39 PM

    why your component doesn't support manifest?

    even it is not supported, you can put configuration in component.js

    Add comment
    10|10000 characters needed characters exceeded