Skip to content

How to render primitives with the "%o" specifier #31

Open
@fflorent

Description

@fflorent

The spec says:

Specifier Description
%o Formats the value as an expandable DOM Element (or JavaScript Object if it is not)

But is that relevant to display the properties of a primitive?

FWIW, Firebug and the Chrome DevTools print the representations of the primitives rather an object view:
firebug display

Same question for the "%O" specifier, BTW. Currently, the only implementation (AFAIK) that follows the spec is the Chrome DevTools and seem to display the primitives with an expand icon (though they don't show any properties).

Chrome DevTools display

Thoughts?

Florent

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