UNPKG

crc

Version:

Module for calculating Cyclic Redundancy Check (CRC) for Node.js and the Browser.

17 lines (13 loc) 284 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = function (model, calc) { var fn = function fn(buf, previous) { return calc(buf, previous) >>> 0; }; fn.signed = calc; fn.unsigned = fn; fn.model = model; return fn; };