@thi.ng/units
Version:
Extensible SI unit creation, conversions, quantities & calculations (incl. ~170 predefined units & constants)
11 lines (10 loc) • 319 B
JavaScript
import { quantity } from "../unit.js";
import { m_s } from "../units/velocity.js";
const SPEED_OF_LIGHT = quantity(299792458, m_s);
const SPEED_OF_SOUND_IN_AIR = quantity(343.14, m_s);
const SPEED_OF_SOUND_IN_WATER = quantity(1482, m_s);
export {
SPEED_OF_LIGHT,
SPEED_OF_SOUND_IN_AIR,
SPEED_OF_SOUND_IN_WATER
};