prefer-flat-math-min-max
UnreleasedConfiguration
rslint.config.ts
Prefer flat Math.min() and Math.max() calls over nesting the same method.
Both functions accept any number of arguments, so same-method nesting is unnecessary.
The rule reports every matching nested built-in Math.min()/Math.max() call. It only autofixes when the flattened arguments are statically primitive and side-effect-free, because flattening can otherwise reorder JavaScript numeric coercion. Non-flattened argument text, including required parentheses, is preserved. Calls through a locally shadowed Math binding are ignored.
This intentionally makes autofixing more conservative than eslint-plugin-unicorn v75.0.0 while preserving the same diagnostic intent.