Spread Operator equivalent in IE - Javascript

后端 未结 5 1482
太阳男子
太阳男子 2020-12-20 22:12

I have a javascript function to populate dropdowns for individual table rows like:

$scope.possibleOptions = getUniqueValues($scope.yypeOptions, \'yypeOption\         


        
5条回答
  •  感情败类
    2020-12-20 22:32

    If you are targeting IE11, since it does not support ES6 features like "=>", you have 2 options:

    1) include a polyfill like babeljs so that the ES6 code works in IE11

    • I have not done this previously but I read that this is what polyfills do

    OR

    2) replace your ES6 code with equivalent ES5 code

    • https://babeljs.io/repl - here you can get ES5 equivalent of your ES6 code.

提交回复
热议问题