amplify-js: I can't use amplify on internet explorer 11

Describe the bug I’m using Angular8 and I included Amplify like below

import Amplify from 'aws-amplify';
import awsconfig from './aws-exports';

Amplify.configure(awsconfig);

I’ve confirmed that it works fine on Chrome and Edge but InternetExplorer displayed the following message

SCRIPT438: Object doesn't support property or method 'from'

I think this might be caused by same as following issue https://github.com/angular/preboot/issues/63

Can you fix it? To Reproduce Steps to reproduce the behavior:

  1. Go to ‘…’
  2. Click on ‘…’
  3. Scroll down to ‘…’
  4. See error

– or –

Link to sample code

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Environment
npx envinfo --system --binaries --browsers --npmPackages --npmGlobalPackages

Smartphone (please complete the following information):

  • Device: PC
  • OS: Windows 10
  • Browser InternetExplorer11
  • Version 11

Additional context Add any other context about the problem here.

Sample code Include additional sample code or a sample repository to help us reproduce the issue. (Be sure to remove any sensitive data)

You can turn on the debug mode to provide more info for us by setting window.LOG_LEVEL = ‘DEBUG’; in your app.

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 2
  • Comments: 32 (7 by maintainers)

Most upvoted comments

Same issue, this needs a fast fix, as it makes it impossible to use amplify for business-applications where IE11 is still used

For me the error is here:

image

@cshouts-tasc Or implement a Babel conversion of the es6 file that is causing the error? I was getting a hickup on a fat arrow in the source code, I think that also came from the es6 file that was part of one of the amplify dependencies.

For me adding import 'core-js/es6/typed'; to polyfills.js (working with angular) helped fix the Uint32Array.from problem

I’m seeing a syntax error in ie11 and if I search the node_module directory, aws-amplify/dist I find the line that comes up when I click the error in IE dev tools. It appears to be related to at least one arrow function in the min file:

t.getSerdePlugin=function(e,n,o){return{applyToStack:s=>{

Seems I am running into the same as @mattiLeBlanc

@michelschmit I’m glad you were able to find an resolution.

We’re still investigating this as there are a couple issues to address:

  1. Documentation for window.fetch & IE11-specific requirements, as IE11 doesn’t have it and it’s a large enough polyfill that including it with Amplify would impact the majority of users.
  2. Several parts of are code have been polyfilled (e.g. Number.isInteger via #185), and it looks like we previously covered the Uint32Array.from feature.