Documentation

Event.BaseEvent

Constructor class for event object.

import {Event} from 'main.core';

const event = new Event.BaseEvent({
	data: {
		item1: '...',
		item2: '...',
	},
});

this.emit('BX.UI.Button:click', event);

Event.BaseEvent.preventDefault

Event.BaseEvent.preventDefault()

Cancels default activity for the event.


Event.BaseEvent.isDefaultPrevented

Event.BaseEvent.isDefaultPrevented(): boolean

Checks if default activity was cancelled in the event handler.


Event.BaseEvent.isTrusted

Event.BaseEvent.isTrusted: boolean

Specifies who sent the event.

When true, the event was sent by the Event.EventEmitter class descendant object.
When false, the event was sent globally via static method .emit



© «Bitrix24», 2001-2024
Up