Search code examples
sapui5

How to prevent SAPUI5 from log output in console?


I developed a Fiori application with SAPUI5 inside of the WEBIde. When I open console of the browser I see some log inside of the console that are generated automatically with SAPUI5.

enter image description here

How can I prevent SAPUI5 from generating unwanted logs?


Solution

  • You could try jQuery.sap.log.setLevel in your Component initialization. Valid parameter values include:

    However, I'm not sure if any of the messages in your screen shot get generated prior to the component being initialized.

    Edit: If your app isn't launched from Fiori Launchpad, you could try setting the log level in your bootstrap code - i.e. in sap.ui.getCore().attachInit().