{"id":31425055,"url":"https://github.com/es-shims/number.prototype.toexponential","last_synced_at":"2025-09-30T04:55:19.029Z","repository":{"id":62354837,"uuid":"401871294","full_name":"es-shims/Number.prototype.toExponential","owner":"es-shims","description":"An ES-spec-compliant Number.prototype.toExponential shim/polyfill/replacement that works as far down as ES3","archived":false,"fork":false,"pushed_at":"2024-12-19T18:17:35.000Z","size":106,"stargazers_count":1,"open_issues_count":1,"forks_count":2,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-09-16T04:46:55.669Z","etag":null,"topics":["ecmascript","exponential","javascript","number","polyfill","shim","toexponential"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/es-shims.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["ljharb"],"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":"npm/es5-shim","community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2021-08-31T23:36:42.000Z","updated_at":"2024-12-19T18:17:38.000Z","dependencies_parsed_at":"2024-12-19T17:28:41.429Z","dependency_job_id":"eabeff26-ec93-447e-9929-6695f8fc079e","html_url":"https://github.com/es-shims/Number.prototype.toExponential","commit_stats":{"total_commits":34,"total_committers":1,"mean_commits":34.0,"dds":0.0,"last_synced_commit":"4b57e286e06dce43e1f6580b1bf7d93de3f16011"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/es-shims/Number.prototype.toExponential","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/es-shims%2FNumber.prototype.toExponential","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/es-shims%2FNumber.prototype.toExponential/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/es-shims%2FNumber.prototype.toExponential/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/es-shims%2FNumber.prototype.toExponential/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/es-shims","download_url":"https://codeload.github.com/es-shims/Number.prototype.toExponential/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/es-shims%2FNumber.prototype.toExponential/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":277632370,"owners_count":25850734,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-30T02:00:09.208Z","response_time":75,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ecmascript","exponential","javascript","number","polyfill","shim","toexponential"],"created_at":"2025-09-30T04:55:12.487Z","updated_at":"2025-09-30T04:55:19.023Z","avatar_url":"https://github.com/es-shims.png","language":"JavaScript","funding_links":["https://github.com/sponsors/ljharb","https://tidelift.com/funding/github/npm/es5-shim"],"categories":[],"sub_categories":[],"readme":"# Number.prototype.toExponential \u003csup\u003e[![Version Badge][npm-version-svg]][package-url]\u003c/sup\u003e\n\n[![github actions][actions-image]][actions-url]\n[![coverage][codecov-image]][codecov-url]\n[![dependency status][deps-svg]][deps-url]\n[![dev dependency status][dev-deps-svg]][dev-deps-url]\n[![License][license-image]][license-url]\n[![Downloads][downloads-image]][downloads-url]\n\n[![npm badge][npm-badge-png]][package-url]\n\nAn ES-spec-compliant Number.prototype.toExponential shim/polyfill/replacement that works as far down as ES3\n\nThis package implements the [es-shim API](https://github.com/es-shims/api) interface. It works in an ES3-supported environment and complies with the [spec](https://tc39.es/ecma262/#sec-number.prototype.exponential).\n\n## Where this is needed\n\nIn particular:\n - Edge 15-17, and the equivalent versions of ChakraCore, have a rounding bug\n - IE \u003c= 11, and Edge \u003c= 14, have a different rounding bug\n - IE 6-8 do not properly throw on ±Infinity as fractionalDigits\n - FF 3.6-86 have a rounding bug\n - Safari \u003c 11 and FF \u003c 50 incorrectly throw on edge cases\n\nIf you are not concerned with supporting these engines, there is no need to use this package.\n\nNote: ES2018 increased the maximum range from 20 to 100. This package does _not_ attempt to patch this difference.\n\n## Getting started\n\n```sh\nnpm install --save number.prototype.exponential\n```\n\n## Usage/Examples\n\n```js\nconsole.log((-3).toExponential()); // \"-3e+0\"\nconsole.log(0x10.toExponential(2)); // \"1.60e+1\"\nconsole.log(1.23456.toExponential(5)); // \"1.23456e+0\"\nconsole.log((-6.9e-11).toExponential(4)); // \"-6.9000e-11\"\n```\n\n## Tests\n\nClone the repo, `npm install`, and run `npm test`\n\n[package-url]: https://npmjs.org/package/number.prototype.exponential\n[npm-version-svg]: https://versionbadg.es/es-shims/Number.prototype.toExponential.svg\n[deps-svg]: https://david-dm.org/es-shims/Number.prototype.toExponential.svg\n[deps-url]: https://david-dm.org/es-shims/Number.prototype.toExponential\n[dev-deps-svg]: https://david-dm.org/es-shims/Number.prototype.toExponential/dev-status.svg\n[dev-deps-url]: https://david-dm.org/es-shims/Number.prototype.toExponential#info=devDependencies\n[npm-badge-png]: https://nodei.co/npm/number.prototype.exponential.png?downloads=true\u0026stars=true\n[license-image]: https://img.shields.io/npm/l/number.prototype.exponential.svg\n[license-url]: LICENSE\n[downloads-image]: https://img.shields.io/npm/dm/number.prototype.exponential.svg\n[downloads-url]: https://npm-stat.com/charts.html?package=number.prototype.exponential\n[codecov-image]: https://codecov.io/gh/es-shims/Number.prototype.toExponential/branch/main/graphs/badge.svg\n[codecov-url]: https://app.codecov.io/gh/es-shims/Number.prototype.toExponential/\n[actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/es-shims/Number.prototype.toExponential\n[actions-url]: https://github.com/es-shims/Number.prototype.toExponential/actions\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fes-shims%2Fnumber.prototype.toexponential","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fes-shims%2Fnumber.prototype.toexponential","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fes-shims%2Fnumber.prototype.toexponential/lists"}