title: What's the most efficient way to execute a bitwise operation on two long hex values in JS?
body: <p>I'm trying to execute an AND operation on two 128-byte hexadecimal values.
  Something like:</p>
  <pre><code>let toReturn = (parseInt(bytesA, 16) &amp; parseInt(bytesB, 16)).toString(16);
  </code></pre>
  <p>seems to work well for values not longer than 0xfffffff. Anything more than that, and I'm starting to get incorrect values.</p>
  <p>I've considered iterating through both values - byte after byte, but my overall code is getting a little heavy, and various 128-byte values would need to be compared 8 times in a loop, that's nested in another loop (up to 50 iterations), all that on page load.</p>
  <p>I'm hoping to find a more efficient solution for that.</p>