Skip to content

[cssom] Serialization of NULL in string #1105

Closed
@upsuper

Description

@upsuper

The algorithm to serialize a string has a separate clause for NULL character which says:

If the character is NULL (U+0000), then the REPLACEMENT CHARACTER (U+FFFD) escaped as code point.

However, this doesn't match behavior of any browser.

Firefox and Chrome serialize NULL character to U+FFFD without escaping it as code point. Edge strips anything after NULL, and Safari serializes it as the character escaped as code point (so \0).

I guess the spec means to do what Firefox and Chrome are currently doing, so probably we should fix the spec text?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions