devela::_dep::web_sys::js_sys::Math

Function trunc

Source
pub fn trunc(x: f64) -> f64 
Available on crate feature dep_web_sys only.
Expand description

The Math.trunc() function returns the integer part of a number by removing any fractional digits.

MDN documentation