MCPcopy Create free account
hub / github.com/GoogleChrome/samples / intArrayFromString

Function intArrayFromString

sqlite-wasm-opfs/jswasm/sqlite3.js:1149–1155  ·  view source on GitHub ↗
(stringy, dontAddNull, length)

Source from the content-addressed store, hash-verified

1147
1148
1149 function intArrayFromString(stringy, dontAddNull, length) {
1150 var len = length > 0 ? length : lengthBytesUTF8(stringy)+1;
1151 var u8array = new Array(len);
1152 var numBytesWritten = stringToUTF8Array(stringy, u8array, 0, u8array.length);
1153 if (dontAddNull) u8array.length = numBytesWritten;
1154 return u8array;
1155 }
1156 var TTY = {ttys:[],init:function () {
1157
1158

Callers 2

sqlite3.jsFile · 0.70
doXHRFunction · 0.70

Calls 2

lengthBytesUTF8Function · 0.70
stringToUTF8ArrayFunction · 0.70

Tested by

no test coverage detected