String at()
Widely available
The at()
method of strings returns the character (one UTF-16 code unit) at an index, including negative indices for getting the character relative to the end of the string. Also known as the relative indexing method.
Compatibility
- Chrome 92 Released on 2021-07-20
- Chrome Android 92 Released on 2021-07-20
- Edge 92 Released on 2021-07-22
- Firefox 90 Released on 2021-07-13
- Firefox for Android 90 Released on 2021-07-13
- Safari 15.4 Released on 2022-03-14
- Safari on iOS 15.4 Released on 2022-03-14
MDN docs
Specifications
- ECMAScript Language Specification, from TC39 (Ecma International).