JavaScript polyfills required for browser compatibility
The LI.FI Widget uses modern JavaScript APIs that may not be supported in older environments. Partners integrating the Widget may need to add polyfills if they need to support older browsers.
Polyfills are only needed if you must support an environment where an API below is marked ❌. The polyfill packages/imports in this page are suggestions—you can use any equivalent polyfill solution as long as it provides the same API behavior.
// Place at the very beginning of your app entry point (before importing the Widget)import 'core-js'
Option B: only what you need (smaller bundle)
// Place at the very beginning of your app entry point (before importing the Widget)import 'core-js/actual/structured-clone'import 'core-js/actual/array/at'import 'core-js/actual/object/has-own'import 'core-js/actual/array/find-last'import 'core-js/actual/array/find-last-index'import 'core-js/actual/array/to-spliced'import 'core-js/actual/array/to-sorted'import 'core-js/actual/array/with'
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"LI.FI","description":"Get the best price execution for any swaps and bridging across EVM chains, Solana, Bitcoin and alt-VMs. Enable trading across all DEX aggregators, bridges, and intent-systems and save hundreds of developer hours.","colors":{"primary":"#5C67FF","light":"#fab6f4","dark":"#5C67FF"},"logo":{"light":"https://mintcdn.com/lifi/EmProAEgMrruLUbI/logo/light.png?fit=max\u0026auto=format\u0026n=EmProAEgMrruLUbI\u0026q=85\u0026s=f435348680e682acea6e3b9af339ed7a","dark":"https://mintcdn.com/lifi/EmProAEgMrruLUbI/logo/dark.png?fit=max\u0026auto=format\u0026n=EmProAEgMrruLUbI\u0026q=85\u0026s=d02539147db168291d7c711beb45d10b"},"favicon":"https://mintcdn.com/lifi/jEGN0oG6bNsdv0a3/logo/favicon.svg?fit=max\u0026auto=format\u0026n=jEGN0oG6bNsdv0a3\u0026q=85\u0026s=35fb6353ca8815e24daf1025135fef38","api":{"openapi":"openapi.yaml"},"appearance":{"default":"dark"},"background":{"color":{"light":"#FAFAFF","dark":"#000B29"}},"navbar":{"links":[{"href":"https://lifihelp.zendesk.com/hc/en-us","label":"Support"}],"primary":{"type":"button","label":"Get Started","href":"https://portal.li.fi/signup"}},"footer":{"socials":{"x":"https://x.com/lifiprotocol","github":"https://github.com/lifinance","website":"https://li.fi/"},"links":[{"header":"Company","items":[{"label":"Careers","href":"https://li.fi/careers"},{"label":"Brand Assets","href":"https://li.fi/brand-assets"},{"label":"About","href":"https://li.fi/"}]},{"header":"Tools","items":[{"label":"LI.FI Explorer","href":"https://explorer.li.fi/?utm_source=lifi\u0026utm_medium=footer_link_tools\u0026utm_campaign=lifi_to_explorer"}]},{"header":"Legal","items":[{"label":"Privacy Policy","href":"https://li.fi/legal/privacy-policy"},{"label":"Terms of Service","href":"https://li.fi/legal/terms-and-conditions"},{"label":"Imprint","href":"https://li.fi/legal/imprint"}]}]},"styling":{"eyebrows":"section","codeblocks":"system","latex":false},"integrations":{"ga4":{"measurementId":"G-NTE1P73M4Q"}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"navigation":{"languages":[{"language":"en","href":"introduction/introduction"},{"language":"zh-Hans","href":"zh-Hans/introduction/introduction"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"lifi","hasAudioNarration":false,"actualSubdomain":"lifi","customDomains":["docs.li.fi"],"gitSource":{"type":"github","owner":"lifinance","repo":"public-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6aeb2e313328f53f4240d888","collectionId":"13724484-1a08-4b50-88c2-b5a5f574cd7e","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6aeb2e313328f53f4240d888"},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6aeb2e313328f53f4240d888","clientVersion":"0.0.4067","searchFilterCounts":[{"language":"en","tag":"Composer","count":56},{"language":"en","tag":"Overview","count":48},{"language":"zh-Hans","tag":"Composer","count":46},{"language":"zh-Hans","tag":"概述","count":44},{"language":"en","tag":"Integrate via Composer API","count":40},{"language":"en","tag":"API Reference","count":34},{"language":"en","tag":"Intents \u0026 Solvers","count":32},{"language":"zh-Hans","tag":"意图与求解器","count":32},{"language":"zh-Hans","tag":"通过 Composer API 集成","count":30},{"language":"zh-Hans","tag":"API 参考","count":29},{"language":"en","tag":"Reference","count":28},{"language":"en","tag":"For Agents","count":21},{"language":"en","tag":"Widget","count":20},{"language":"zh-Hans","tag":"Widget","count":20},{"language":"zh-Hans","tag":"参考文档","count":19},{"language":"en","tag":"Getting Started","count":16},{"language":"en","tag":"General API","count":16},{"language":"zh-Hans","tag":"通用 API","count":16},{"language":"zh-Hans","tag":"企业级功能","count":15},{"language":"zh-Hans","tag":"入门","count":14}]},"assistantConfig":{},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"widget/polyfill-requirements","slug":"/widget/polyfill-requirements","pageMetadata":{"title":"Polyfill Requirements","description":"JavaScript polyfills required for browser compatibility","href":"/widget/polyfill-requirements"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"JavaScript polyfills required for browser compatibility\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,Heading,Note,Table}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`The LI.FI Widget uses modern JavaScript APIs that may not be supported in older environments. Partners integrating the Widget may need to add polyfills if they need to support older browsers.`}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`Polyfills are only needed if you must support an environment where an API below is marked ❌. The polyfill packages/imports in this page are `,_jsx(_components.strong,{children:`suggestions`}),`—you can use any equivalent polyfill solution as long as it provides the same API behavior.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`browser-\u0026-api-support`,children:`Browser \u0026 API Support`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`API`}),_jsx(_components.th,{children:`Polyfill`}),_jsx(_components.th,{children:`iOS 15.0-15.3`}),_jsx(_components.th,{children:`iOS 15.4+`}),_jsx(_components.th,{children:`iOS 16.0+`}),_jsx(_components.th,{children:`Chrome 92+`}),_jsx(_components.th,{children:`Firefox 92+`}),_jsx(_components.th,{children:`Safari 15.4+`}),_jsx(_components.th,{children:`Safari 16.0+`}),_jsx(_components.th,{children:`Samsung 16.0+`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`structuredClone()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/structured-clone`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Array.at()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/array/at`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Object.hasOwn()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/object/has-own`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Array.findLast()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/array/find-last`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Array.findLastIndex()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/array/find-last-index`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Array.toSpliced()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/array/to-spliced`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Array.toSorted()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/array/to-sorted`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Array.with()`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`core-js/actual/array/with`})}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`❌`}),_jsx(_components.td,{children:`✅`}),_jsx(_components.td,{children:`✅`})]})]})]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Legend:`}),` ❌ Not supported (requires polyfill) | ✅ Fully supported`]}),`\n`,_jsx(Heading,{level:`2`,id:`polyfill-setup-examples`,children:`Polyfill Setup (Examples)`}),`\n`,_jsx(Heading,{level:`3`,id:`install-a-polyfill-library`,children:`Install a polyfill library`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`npm`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` install`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` core-js`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`import-polyfills-choose-one-approach`,children:`Import polyfills (choose one approach)`}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Option A: simplest (larger bundle)`})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Place at the very beginning of your app entry point (before importing the Widget)`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js'`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Option B: only what you need (smaller bundle)`})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`9`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`9`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Place at the very beginning of your app entry point (before importing the Widget)`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/structured-clone'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/array/at'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/object/has-own'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/array/find-last'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/array/find-last-index'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/array/to-spliced'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/array/to-sorted'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'core-js/actual/array/with'`})]}),`\n`]})})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"system","config":{},"pageMetadata":{"title":"Polyfill Requirements","description":"JavaScript polyfills required for browser compatibility","href":"/widget/polyfill-requirements"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Browser \u0026 API Support","slug":"browser-\u0026-api-support","depth":2,"children":[]},{"title":"Polyfill Setup (Examples)","slug":"polyfill-setup-examples","depth":2,"children":[{"title":"Install a polyfill library","slug":"install-a-polyfill-library","depth":3,"children":[]},{"title":"Import polyfills (choose one approach)","slug":"import-polyfills-choose-one-approach","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/lifi/951d8dd0c2dbce84/plausible.js","/_mintlify/custom/lifi/8e3c41579c236ea7/scripts/translate-docs.js","/_mintlify/custom/lifi/b34903975490ec23/scripts/generate-md-redirects.js","/_mintlify/custom/lifi/516472b23ab068ad/scripts/check-links.js","/_mintlify/custom/lifi/70364f7a7384bb43/scripts/markdown-chunker.js","/_mintlify/custom/lifi/6c99617851837b30/scripts/translation-config.js","/_mintlify/custom/lifi/8f88293865b45873/scripts/verify-translation-coverage.js"],"subdomain":"lifi","siteName":"LI.FI","title":"Polyfill Requirements - LI.FI","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/widget/polyfill-requirements","matchLevel":0},"zh-Hans":{"href":"/zh-Hans/widget/polyfill-requirements","matchLevel":1}}},"lastModified":"2026-02-13T13:36:26.686Z","originalFileLocation":"widget/polyfill-requirements.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"JavaScript polyfills required for browser compatibility\">\u003cmeta data-mint-head name=\"application-name\" content=\"LI.FI\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Polyfill Requirements - LI.FI\">\u003cmeta data-mint-head property=\"og:description\" content=\"JavaScript polyfills required for browser compatibility\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"LI.FI\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.li.fi/widget/polyfill-requirements\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://lifi.mintlify.app/_mintlify/api/og/v2?division=Misc.\u0026amp;title=Polyfill+Requirements\u0026amp;description=JavaScript+polyfills+required+for+browser+compatibility\u0026amp;theme=bbd760f308f6962e114ab426\u0026amp;signature=94937ff4434e62d3c263b2bbbe31998efa2cf4faed1e40bf24067f024596c4b3\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Polyfill Requirements - LI.FI\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"JavaScript polyfills required for browser compatibility\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://lifi.mintlify.app/_mintlify/api/og/v2?division=Misc.\u0026amp;title=Polyfill+Requirements\u0026amp;description=JavaScript+polyfills+required+for+browser+compatibility\u0026amp;theme=bbd760f308f6962e114ab426\u0026amp;signature=94937ff4434e62d3c263b2bbbe31998efa2cf4faed1e40bf24067f024596c4b3\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"LI.FI\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#5C67FF\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.li.fi/widget/polyfill-requirements\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/widget/polyfill-requirements.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://docs.li.fi/widget/polyfill-requirements\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh-Hans\" href=\"https://docs.li.fi/zh-Hans/widget/polyfill-requirements\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://docs.li.fi/widget/polyfill-requirements\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.li.fi/#organization\",\"name\":\"LI.FI\",\"url\":\"https://docs.li.fi\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/lifi/EmProAEgMrruLUbI/logo/light.png?fit=max\u0026auto=format\u0026n=EmProAEgMrruLUbI\u0026q=85\u0026s=f435348680e682acea6e3b9af339ed7a\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.li.fi#website\",\"name\":\"LI.FI\",\"url\":\"https://docs.li.fi\",\"publisher\":{\"@id\":\"https://docs.li.fi/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.li.fi/widget/polyfill-requirements#webpage\",\"url\":\"https://docs.li.fi/widget/polyfill-requirements\",\"name\":\"Polyfill Requirements\",\"description\":\"JavaScript polyfills required for browser compatibility\",\"dateModified\":\"2026-02-13T13:36:26.686Z\",\"isPartOf\":{\"@id\":\"https://docs.li.fi#website\"},\"breadcrumb\":{\"@id\":\"https://docs.li.fi/widget/polyfill-requirements#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.li.fi/widget/polyfill-requirements#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Misc.\",\"item\":\"https://docs.li.fi/widget/compatibility\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Polyfill Requirements\",\"item\":\"https://docs.li.fi/widget/polyfill-requirements\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.li.fi/widget/polyfill-requirements#article\",\"headline\":\"Polyfill Requirements\",\"name\":\"Polyfill Requirements\",\"description\":\"JavaScript polyfills required for browser compatibility\",\"url\":\"https://docs.li.fi/widget/polyfill-requirements\",\"mainEntityOfPage\":{\"@id\":\"https://docs.li.fi/widget/polyfill-requirements#webpage\"},\"dateModified\":\"2026-02-13T13:36:26.686Z\",\"publisher\":{\"@id\":\"https://docs.li.fi/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.li.fi#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"LI.FI\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"LI.FI","nav":{"global":null,"languages":[{"language":"en","tabs":[{"tab":"Overview","pages":[{"title":"Overview","href":"/introduction/introduction"}]},{"tab":"Enterprise (New)","pages":[{"title":"Enterprise (New)","href":"/enterprise/overview"}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api-reference/introduction"}]},{"tab":"SDK","pages":[{"title":"SDK","href":"/sdk/overview"}]},{"tab":"Widget","groups":[{"group":"Getting Started","pages":[{"title":"LI.FI Widget Overview","href":"/widget/overview"}]},{"group":"Basic Setup","pages":[{"title":"Install Widget","href":"/widget/install-widget"},{"title":"Select Widget Layout","href":"/widget/select-widget-layout"},{"title":"Configure Widget","href":"/widget/configure-widget"},{"title":"Customize Widget","href":"/widget/customize-widget"},{"title":"Monetize Widget","href":"/widget/monetize-widget"}]},{"group":"Advanced","pages":[{"title":"Widget Events","href":"/widget/widget-events"},{"title":"Wallet Management","href":"/widget/wallet-management"},{"title":"Internationalization","href":"/widget/internationalization"},{"title":"Widget API Reference","href":"/widget/widget-api-reference"}]},{"group":"Widget Light (iframe)","pages":[{"title":"Widget Light Overview","href":"/widget/widget-light-overview"},{"title":"Install Widget Light","href":"/widget/widget-light-installation"},{"title":"Configure Widget Light","href":"/widget/widget-light-configuration"},{"title":"Widget Light Events","href":"/widget/widget-light-events"},{"title":"Widget Light Wallet Management","href":"/widget/widget-light-wallet-management"},{"title":"Widget Light API Reference","href":"/widget/widget-light-api-reference"}]},{"group":"Misc.","pages":[{"title":"Compatibility with Next.js, Remix, Nuxt, etc.","description":"Integrate the widget with your Next.js, Remix, Nuxt, or other framework application","href":"/widget/compatibility"},{"title":"Polyfill Requirements","href":"/widget/polyfill-requirements"},{"title":"Migrate from v3 to v4","description":"Migration guide for upgrading LI.FI Widget v3 to v4","href":"/widget/migrate-from-v3-to-v4"},{"title":"Migrate from v2 to v3","href":"/widget/migrate-from-v2-to-v3"}]}]},{"tab":"Composer","pages":[{"title":"Composer","href":"/composer/overview"}]},{"tab":"Earn","pages":[{"title":"Earn","href":"/earn/overview"}]},{"tab":"Perps","pages":[{"title":"Perps","href":"/perps/overview"}]},{"tab":"Intents \u0026 Solvers","pages":[{"title":"Intents \u0026 Solvers","href":"/lifi-intents/introduction"}]},{"tab":"For Agents","pages":[{"title":"For Agents","href":"/agents/overview"}]},{"tab":"Widget Playground","href":"https://playground.li.fi/"},{"tab":"Bigmi","pages":[{"title":"Bigmi","href":"/bigmi/overview"}]},{"tab":"Guides","pages":[{"title":"Guides","href":"/guides/gas-options"}]},{"tab":"FAQs","pages":[{"title":"FAQs","href":"/faqs/fees-monetization"}]}]},{"language":"zh-Hans","pages":[{"title":"zh-Hans","href":"/zh-Hans/widget/polyfill-requirements"}]}]},"basePath":"","title":"Polyfill Requirements - LI.FI","buildId":"dpl_9VVk5y1P8k1ATeJguVngy9Q3cmbD","deploymentId":"dpl_9VVk5y1P8k1ATeJguVngy9Q3cmbD","dynamics":[],"chunks":[]}