CharacterBoundsUpdateEvent: CharacterBoundsUpdateEvent() constructor
Limited availability
This feature is not Baseline because it does not work in some of the most widely-used browsers.
Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
The CharacterBoundsUpdateEvent()
constructor returns a new CharacterBoundsUpdateEvent
object.
Syntax
js
new CharacterBoundsUpdateEvent(type)
new CharacterBoundsUpdateEvent(type, options)
Parameters
type
-
A string representing the type of the event. Possible values:
"characterboundsupdate"
. options
Optional-
An optional object with the following properties:
rangeStart
-
A number to set the offset of the first character within the editable text region which this event applies to.
rangeEnd
-
A number to set the offset of the last character within the editable text region which this event applies to.
Specifications
Specification |
---|
EditContext API # dom-characterboundsupdateevent-constructor |
Browser compatibility
BCD tables only load in the browser
See also
- The
CharacterBoundsUpdateEvent
interface it belongs to.