MCPcopy Create free account
hub / github.com/microsoft/SandDance / rightmostDigit

Function rightmostDigit

docs/app/js/sanddance-app.js:109973–109980  ·  view source on GitHub ↗
(str, dec)

Source from the content-addressed store, hash-verified

109971 };
109972}
109973function rightmostDigit(str, dec) {
109974 let i = str.lastIndexOf("e"), c;
109975 if (i > 0) return i;
109976 for(i = str.length; --i > dec;){
109977 c = str.charCodeAt(i);
109978 if (c >= 48 && c <= 57) return i + 1; // is digit
109979 }
109980}
109981function numberLocale(locale1) {
109982 const format = memoize(locale1.format), formatPrefix = locale1.formatPrefix;
109983 return {

Callers 1

trimZeroesFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected