UNPKG
unlerp
Version:
latest (1.0.1)
1.0.1
1.0.0
opposite of lerp; get normalized range between two bounds
github.com/mattdesl/unlerp
mattdesl/unlerp
unlerp
/
index.js
3 lines
•
89 B
JavaScript
View Raw
1
2
3
module.exports
=
function
range
(
min
,
max
,
value
)
{
return
(
value
-
min
)
/
(
max
-
min
)
}