pseudo-dom
    Preparing search index...

    Function createEvent

    • Create an event of the kind which suits its type (a click is a MouseEvent, a keydown a KeyboardEvent, ...). By default this is like using the constructor of the event in a script: nothing bubbles or can be cancelled unless the init says so, and the event is not trusted. With browser: true the event is created the way the browser creates it, using the standard options for its type (see eventDefaults), and trusted: true makes it look like it came from a real user action (isTrusted).

      Parameters

      • type: string

        The type of the event, such as click

      • init: { [option: string]: any } = {}

        The options for the event (bubbles, cancelable, composed and those of its kind of event)

      • options: CreateEventOptions = {}

        Whether the browser is creating the event, and whether it is trusted

      Returns EventService