Skip to content

Mandate a default value for boolean dictionary members? #1485

@saschanaz

Description

@saschanaz

What is the issue with the Web IDL Standard?

It's very easy to just write boolean foo; in dictionaries even when it's not really expected to be tristate.

There are certainly intentional tristate booleans like passive of EventListenerOptions, but maybe we should guide the new specs to use enums for such multistate instead or use nullable booleans (boolean? foo = null)?

(I don't have a definite list of accidental tristate booleans in specs, for now this is just what I observed when dealing with Gecko IDL.)

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