Skip to content

Implement console.context()Β #29560

@nchevobbe

Description

@nchevobbe

console.context(label) returns a new object with a lot of the console members. Messages emitted from calling the method from this created object can carry the context name, which can be used to categorize/filter them more easily.

console.context is available in Chrome and Node (even though logs emitted from it are not visible, see nodejs/node#56634), and is currently being implemented in Firefox (https://bugzilla.mozilla.org/show_bug.cgi?id=1948870)


See the whatwg issue (whatwg/console#193) and the (WIP) PR to specifiy it (whatwg/console#244)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions