module.exports = function clip(val, min, max) {
	return Math.max(Math.min(val, max || val), min || 0)
}

module.exports = function clip(val, min, max) {
	return Math.max(Math.min(val, max), min)
}

remove default values - they dont work for some negative/zero values