IE11 syntax error due to destructuring
See original GitHub issueCurrent behavior
Using version 8.0.1 in IE11 I get a syntax error in the SweetAlert constructor due to destructuring. This causes my app not to load.
Expected behavior
Shouldn’t error in IE11
Live demo
I can’t replicate this issue with your template as it does seem to work in IE11. But using the latest version in my sandbox repo I get the same issue:
https://github.com/afisher88/sweetalert2-sandbox
I can get around this by transpiling my node_modules folder but I don’t really want to have to do this.
rules: [
{
test: /\.(js|jsx)$/,
exclude: /(node_modules)/, // Remove this line
use: {
loader: 'babel-loader',
options: {
presets: ['@babel/preset-env', '@babel/preset-react'],
plugins: [
'@babel/plugin-proposal-object-rest-spread',
'@babel/transform-spread',
'@babel/plugin-proposal-class-properties'
]
}
}
},
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Destructuring assignment not working in IE 11 even after ...
Destructuring assignment not working in IE 11 even after using babel ... Fails on ({getState}), error in console is 'Expected Identifier' .
Read more >IE11 and the Missing Polyfills - DEV Community
Once you configured - "modern + IE11" it will remove polyfills for IE9-10, as well A LOT of polyfills for Android related browsers....
Read more >[Solved]-ng-annotate error with Babel and destructuring-babel.js
I have similar problem, I just simply changed the order in gulp pipe to: babel --> annotate. ng-annotate does not support new JS...
Read more >Syntax error in IE 11 - jQuery Forum
Hi there, My code works just fine in Chrome and Edge but in IE 11, I get syntax error at line var GDN....
Read more >Vue instantsearch - Open Q&A - Algolia Community
SyntaxError: Expected identifier in ... it works now in Edge (thanks to stackoverflow). ... Another thing: I've just checked in IE11 your codepen ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
🎉 This issue has been resolved in version 8.0.2 🎉
The release is available on:
Your semantic-release bot 📦🚀
No problem, thanks for fixing so quickly!