'use strict';

Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });

function clamp(value, bound1, bound2) {
    if (bound2 == null) {
        return Math.min(value, bound1);
    }
    return Math.min(Math.max(value, bound1), bound2);
}

exports.clamp = clamp;
