Skip to content
This repository was archived by the owner on Aug 30, 2024. It is now read-only.

Latest commit

 

History

History
25 lines (16 loc) · 814 Bytes

File metadata and controls

25 lines (16 loc) · 814 Bytes

useLogger

The useLogger hook allows you to pump logs to the browser console to see things as they happen. By default, the level of logging is set to LogLevel.info, with the possible options being LogLevel.info, LogLevel.warn and LogLevel.error.

import { useLogger } from '@dolbyio/comms-uikit-react';

Members

Name Type Description
log (level: LogLevel, message: string, ...optionalParams: any[]) => void Method for create log.

Examples

React

Remove specific error from sdk errors

const { log } = useLogger();

log(LogLevel.warn, 'Some warning');