Skip to content

Map is undefined in ie9 #1583

@kwzm

Description

@kwzm
  • Operating System: win7 64bit
  • Node Version: 8.12.0
  • NPM Version: 6.4.1
  • webpack Version: 4.9.1
  • webpack-dev-server Version: 3.1.9
  • This is a bug
  • This is a modification request

Code

use create-react-app

Expected Behavior

webpack-dev-server can run in ie9

Actual Behavior

I use create-react-app init a application, and view the page in ie9 in dev environment, but found this error:

default

in English is Map is undefined

I know webpack-dev-server from 2.8.0 use es6 syntax, so I want use babel to translate it:

  1. I use babel-loader to compile it:

default

  1. I try to use @babel/polyfill
    import '@babel/polyfill'

  2. I try to use core-js
    import 'core-js/es/array/map'

But never work, the error is still there.

For Bugs; How can we reproduce the behavior?

use create-react-app init a app and npm start then open ie9 view the page

For Features; What is the motivation and/or use-case for the feature?

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