Debug
Debug mode writes each event, its checks and the response of QuickPipe to the browser console. Use it when an event does not arrive.
Procedure
Start debug mode. With the script tag:
jslg('debug', true);With npm:
tslg.debug(true);Open the browser console and do the action again.
Stop debug mode:
jslg('debug', false);
Result
The console shows each event before the client sends it, the reason when the client drops an event, and the response of each batch.
Messages
| Message | Reason | Fix |
|---|---|---|
| Invalid event name | The name has a character that the client does not accept | Use a-z, 0-9, _, ., : and - only |
| Properties too large | The properties are larger than 32 KB, deeper than 5 levels or have more than 200 keys | Send fewer properties |
| No consent | The visitor did not give consent | Refer to Set consent |
| Secret key in a browser | The key starts with lg-sec- | Use the publishable key |
| Request failed, retry | The network or the endpoint did not answer | The client tries again. No action is necessary. |