Skip to content

Passing a non-breaking space as an attribute name raises a runtime error #10

@magopian

Description

@magopian

Disclaimer: I believe the bug is in the compiler (see elm/html#46 and elm/html#47).

As it's likely not going to be fixed (for performance reasons), I guess it makes sense to fix it in this library.

To reproduce, try parsing and rendering something like <img \u{00a0} /> (example in this Ellie), and there will be a runtime error in the console: InvalidCharacterError: String contains an invalid character.

At least in some cases, this results in an infinite loop of rendering/runtime errors, which brings the browser (and the whole computer) to its knees.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions