Requirejs + IE8: undefined object is null or not an object

I get an error only in IE related to the require.js plugin.

I have the following code in require.js (line 1061):

 if (plugin.normalize) {

IE 8 returns this error:

Message: "normalize" is null or not an object

Line: 1061 Char: 25

I checked the debugger and the plugin object exists, normalized to undefined. In javascript, this should be evaluated as false and not accept an if condition. However, for some reason IE throws this error and prevents my page from loading correctly. Does anyone know why this is happening?

Ironically, if I change line 1061 to this:

if (plugin.normalize !== undefined && plugin.normalize !== null && plugin.normalize !== false) {

IE8 ... , , , require.js, IE, .

+5
2

, , , (404), , , , , ( IE8) , .

0

All Articles