generic javascript number/string formatting (bytes, milliseconds e etc)