Skip to content

Can file name be appended to the log message? #60

Open
@sudhashri

Description

@sudhashri

Is there any way to include the Component name along with the string being logged? For example if I'm logging "Function getMusicData() called" inside a Component called Music. I would want my logged message to look like "MusicComponent : Function getMusicData() called".

One way to do this could be declaring a constant string, "MusicComponent : " and appending this, each time I log something. This would be very hectic where there are 100s of lines to be logged and 100s of files.

This is more of a feature request rather than a issue. I'm quite new to angular2-logger. If this feature already exists, I might have missed it. Can anyone point me to the usage, if it already exists?

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions