Skip to content

Why string.replaceAll was polyfilled by esnext.string.replaceAll when setting useBuiltIns: entry #107

Open
@maoxiaoke

Description

@maoxiaoke

Here is my @babel/preset-env settings:

{
    "presets": [
    [
      "@babel/preset-env",
      {
        "useBuiltIns": "usage",
	 "corejs": 3
      }
    ]
  ],
  "targets": {
    "chrome": "58",
    "ie": "11"
  }
}

And I found usageGlobal inject polyfill within esnext.string.replaceAll as fallback, while entryGlobal not.

I'm really curious about this. Could someone explain this to me?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions