keymanapp / keymanapp/keyman

bug(web): KMWString substring methods do not properly match behavior of native String equivalents

Open
#13,728 0 comments 0 reactions 0 assignees View on GitHub
bug web/
Dominant language
Pascal
Stars
534
Forks
143
Avg merge
2d 10h
Merged PRs (30d)
113

Description

> Interestingly, I found a few discrepancies on a few of the utility methods:
>
> .kmwSlice and the substring methods don't quite align with the full spec for their native String counterparts as specified on MDN. They are "fine" as far as our existing use-cases for the methods go, though.

Posted by @jahorton in the description of #13719.

Notes can be seen in comments in their corresponding unit tests introduced by that PR.

I _believe_ that we don't currently use the cases that aren't properly being handled, so this is likely low priority. We should be aware that this is a thing, though, in case we ever do start using one of the mismatching cases.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.