前端 uni-app 重写: 9页面 H5

This commit is contained in:
zhiqui
2026-11-15 15:09:37 +08:00
parent 513b53672e
commit ea7c2529e9
24104 changed files with 3667749 additions and 0 deletions
+22
View File
@@ -0,0 +1,22 @@
'use strict';
var $ = require('../internals/export');
var sign = require('../internals/math-sign');
// eslint-disable-next-line es/no-math-cbrt -- required for testing
var $cbrt = Math.cbrt;
var abs = Math.abs;
var pow = Math.pow;
// imprecise in FF < 48 (`cbrt(64)`) and with glibc `cbrt` (`cbrt(27)`), each check catches only one of them
var FORCED = !$cbrt || $cbrt(27) !== 3 || $cbrt(64) !== 4;
// `Math.cbrt` method
// https://tc39.es/ecma262/#sec-math.cbrt
$({ target: 'Math', stat: true, forced: FORCED }, {
cbrt: function cbrt(x) {
var n = +x;
var y = sign(n) * pow(abs(n), 1 / 3);
// Newton-Raphson refinement for better precision
return n !== 0 && isFinite(n) ? (2 * y + n / (y * y)) / 3 : y;
}
});