Debug Settings - Storm JS Player Core
In this guide, you will get to know all the configuration options for debugging the Storm JS Player Core.
Sample Code
const streamConfig = {
stream: {
... // stream configuration
},
settings: {
... // basic configuration
debug: {
console: {
enabled: true,
logTypes: ["ERROR", "WARNING", "SUCCESS", "INFO", "TRACE"],
monoColor: false,
},
container: {
enabled: true,
logTypes: ["ERROR", "WARNING", "SUCCESS", "INFO", "TRACE"],
monoColor: false,
containerID: "logContainer"
},
playbackController: true,
playerUnit: true,
qualityController: true,
stageController: true
}
}
};
Description of Fields and Parameters
| Parameter name | Parameter type | Required | Default | Description |
|---|---|---|---|---|
console | Object | No | {enabled: false} | Defines tracing options for the player that will be output to the browser's console. For more reference, please check debug console table. |
container | Object | No | {enabled: false} | Defines tracing options for the player that will be output to the provided HTML container. For more reference, please check debug container table. |
playbackController | boolean | No | false | Outputs dedicated logs for the Playback Controller, which manages actions such as subscriptions, play/pause operations, and more. |
playerUnit | boolean | No | false | Outputs dedicated logs for the internal player (MSE, HLS, WebRTC) and its buffer control mechanisms |
qualityController | boolean | No | false | Outputs dedicated logs for the Quality Controller, which manages available and selected quality presets, as well as the active stream. |
stageController | boolean | No | false | Outputs dedicated logs for the Stage Controller, which manages player resizing strategies and the placement of library elements within the document's DOM tree. |
Debug Console Configuration
| Parameter name | Parameter type | Required | Default | Description |
|---|---|---|---|---|
enabled | boolean | No | false | Works as an ON/OFF switch for this option. |
logTypes | Array (string) | No | ERROR | INFO | TRACE | WARNING | SUCCESS | Decides which log types will be output using this channel. Log types are: ERROR, INFO, TRACE, WARNING, and SUCCESS. |
monoColor | boolean | No | false | By default, each log type has got its color. However, if you wish to keep logs a single color (for a specific player by given id), you can switch this option to true. |
Debug Container Configuration
| Parameter name | Parameter type | Required | Default | Description |
|---|---|---|---|---|
enabled | boolean | No | false | Works as an ON/OFF switch for this option. |
logTypes | Array (string) | No | ERROR | INFO | TRACE | WARNING | SUCCESS | Decides which log types will be output using this channel. Log types are: ERROR, INFO, TRACE, WARNING, and SUCCESS. |
containerID | string | yes | - | HTML container for the logs (id). |
monoColor | boolean | No | false | By default, each log type has got its color. However, if you wish to keep logs a single color (for a specific player by given id), you can switch this option to true. |
Next Step
For the next step please check our Storm JS Player Core - Events Basics guide where you'll learn about events and how to react to them via callbacks.