DiviArea.Utils.toMilliseconds()

DiviArea.Utils.toMilliseconds(value)

Converts a CSS timing value into a numeric value that represents the millisecond duration.

E.g. “1000ms” = 1000, “1.25s” = 1250

Params

value string, required
The CSS timing value to convert. Supported units are “s” and “ms”

Returns

An integer value that represents the duration in milliseconds, or 0 if the input value could not be converted.

Notes

No notes

Was this article helpful?

Related Articles

Need Support?

Can't find the answer you're looking for?
Get in touch with us