reports/frontend/node_modules/es-toolkit/dist/compat/math/add.d.ts
jtricerolph 1c411e402e Add settings page for managing forecasting API key and URL via UI
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-20 14:37:36 +00:00

19 lines
No EOL
657 B
TypeScript

//#region src/compat/math/add.d.ts
/**
* Adds two numbers while safely handling `NaN` values.
*
* This function takes two numbers and returns their sum. If either of the numbers is `NaN`,
* the function returns `NaN`.
*
* @param value - The first number to add.
* @param other - The second number to add.
* @returns The sum of the two numbers, or `NaN` if any input is `NaN`.
*
* @example
* const result1 = add(2, 3); // result1 will be 5
* const result2 = add(5, NaN); // result2 will be NaN
* const result3 = add(NaN, 10); // result3 will be NaN
*/
declare function add(value: number, other: number): number;
//#endregion
export { add };