formats.exposed/public/png/parsePngUint.js

9 lines
177 B
JavaScript
Raw Normal View History

// @ts-check
/**
* @param {Uint8Array} bytes
* @returns {number}
*/
export default (bytes) =>
new DataView(bytes.buffer, bytes.byteOffset, bytes.byteLength).getUint32(0);