Join MDN and developers like you at Mozilla's View Source conference, 12-14 September in Berlin, Germany. Learn more at https://viewsourceconf.org

anchorOffset Redirect 1

Summary

Returns the number of characters that the selection's anchor is offset within the anchorNode.

Syntax

sel.anchorOffset

Notes

This number is zero-based. If the selection begins with the first character in the anchorNode, 0 is returned.

Document Tags and Contributors

 Contributors to this page: Sheppy
 Last updated by: Sheppy,