MCPcopy Create free account
hub / github.com/reactjs/react-rails / utf16leSlice

Function utf16leSlice

lib/assets/javascripts/JSXTransformer.js:978–985  ·  view source on GitHub ↗
(buf, start, end)

Source from the content-addressed store, hash-verified

976}
977
978function utf16leSlice (buf, start, end) {
979 var bytes = buf.slice(start, end)
980 var res = ''
981 for (var i = 0; i < bytes.length; i += 2) {
982 res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256)
983 }
984 return res
985}
986
987Buffer.prototype.slice = function slice (start, end) {
988 var len = this.length

Callers 1

JSXTransformer.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected