The missing JavaScript range function