KeyboardEvent: isComposing property
MDN Web Docs · نسخهٔ df622a2a1c1e · CC BY-SA 2.5 و مجوز جداگانهٔ ناشر برای نمونهکد
{{APIRef("UI Events")}}
The **KeyboardEvent.isComposing** read-only property returns a boolean value indicating if the event is fired within a composition session, i.e., after {{domxref("Element/compositionstart_event", "compositionstart")}} and before {{domxref("Element/compositionend_event", "compositionend")}}.
Value
A boolean.
Examples
js
const kbdEvent = new KeyboardEvent("syntheticKey", false);
console.log(kbdEvent.isComposing); // return falseSpecifications
{{Specifications}}
Browser compatibility
{{Compat}}
See also
- {{domxref("Element/compositionstart_event", "compositionstart")}} and {{domxref("Element/compositionend_event", "compositionend")}}
- {{domxref("KeyboardEvent")}}