Issue #1996 - Implement at() method on built-in indexables.

Resolves #1996
This commit is contained in:
Moonchild 2022-08-29 21:52:04 +00:00 committed by roytam1
commit 59cf6bd808
6 changed files with 112 additions and 1 deletions

View file

@ -2847,6 +2847,9 @@ static const JSFunctionSpec string_methods[] = {
/* Python-esque sequence methods. */
JS_FN("concat", str_concat, 1,0),
JS_SELF_HOSTED_FN("slice", "String_slice", 2,0),
/* ES2022 additions */
JS_SELF_HOSTED_FN("at", "String_at", 1,0),
/* HTML string methods. */
JS_SELF_HOSTED_FN("bold", "String_bold", 0,0),