`import` is the keyword in IE even it's a property
See original GitHub issue function SystemJS () {
this[REGISTRY] = {};
}
var systemJSPrototype = SystemJS.prototype;
systemJSPrototype.import = function (id, parentUrl) {
var loader = this;
return Promise.resolve(loader.prepareImport())
.then(function() {
return loader.resolve(id, parentUrl);
})
.then(function (id) {
var load = getOrCreateLoad(loader, id);
return load.C || topLevelLoad(loader, load);
});
};
systemJSPrototype.import
is work in the modern browser, but it doesn’t work in IE
even
const obj = {
import: () => {} // throw in IE
}
function Module () {}
Module.import = function () {} // throw in IE
System.import('/xxx.js'); // throw in IE
This makes system.js not work in IE(including IE11) at all.
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
How to avoid module import when in IE - Stack Overflow
It's just this one package giving me troubles. It's calling animejs with a bunch of extentions extentions that are not compatible with IE...
Read more >import - JavaScript - MDN Web Docs - Mozilla
The static import declaration is used to import read-only live bindings which are exported by another module. The imported bindings are ...
Read more >Python import: Advanced Techniques and Tips
In Python, you use the import keyword to make code in one module available in another. Imports in Python are important for structuring...
Read more >Static import in Java - GeeksforGeeks
With the help of static import, we can access the static members of a class directly without class name or any object. For...
Read more >Using Import-DSCResource - PowerShell | Microsoft Learn
Import-DSCResource is a dynamic keyword that can only be used inside a Configuration script block. It is used to import the resource modules ......
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
@axetroy as mentioned above there are other concerns here regarding IE<11 support. The only version of IE that is supported is IE11 (within which import is supported without quotes).
@joeldenning This is not a polyfill problem.
Is this my description is not clear enough?
I mean
import
is a keyword in IE(7,8,9,10,11).Even if it’s a property like
object.import = function () {}
This will cause the exception to be unusable in IE.
This is not a problem that polyfills can solve.