...
Logs are enabled by default but they can be enabled/disabled in the followings ways.
Webpage level
When loading ctlive sdk into the hosting web page, logs can be enabled or disabled for all users opening that specific webpage.
...
Code Block |
---|
<script type="text/javascript" async src="http://<host>/livechat/stresstest/lib/livechatsdk.js?log=false"></script> |
Session level
Even at webpage logs are disabled, for a specific session, logs are enabled using an api via browser console, e.g. for development or troubleshooting purpose. The setting is persistent because it’s stored using browser localStorage related to the domain page.
...
Api | Description | Values | Default |
---|---|---|---|
lichaUtil.debug() | Enable/Disable logs | true/false | true |
lichaUtil.resetDebug() | Reset to the webPage level | none | N/A |
lichaUtil.isDebug() | Return debug value | node | N/A |
Usage
Open browser console (F12) and type lichaUtil.debug() to enable log
...
Setting is persistent at browser level, because it’s stored on webpage localStorage.
CAVEATS
A minimal log level is always present event when logs are disabled.
error logs are not disalable.