Nov 20, 2013, 9:06 AM
[CLOSED] Component rendered before initialization scripts using placeholder with ResourceMode.Script with MVC
The following seems to only be an issue with MVC when using ResourceMode.Script. I am finding that the Statusbar component has its initialization script written to the head before the rest of the Ext.NET initialization scripts, resulting in JavaScript errors (Ext is not defined, because Statusbar JS is using it before the Ext.NET initialization scripts have loaded).
I spent ages trying to reproduce this in a cut down example (thinking Viewport had something to do with it!) but Daniil was able to provide the simplest case of all!
I spent ages trying to reproduce this in a cut down example (thinking Viewport had something to do with it!) but Daniil was able to provide the simplest case of all!
@{
var X = Html.X();
}
<!DOCTYPE html>
<html>
<head>
<title>ResourcePlaceHolder ResourceMode.Script test</title>
@X.ResourcePlaceHolder(ResourceMode.Script)
</head>
<body>
@X.ResourceManager()
@X.StatusBar()
</body>
</html>
Note - If you change ResourceMode to ResourceMode.ScriptFiles, then it is okay.
- We have found this to be the case for Statusbar, I am not sure if others are affected (most others I have tried seem fine)
- This could be related to this thread, but I am not sure: http://forums.ext.net/showthread.php...-was-not-found
Last edited by Daniil; Nov 20, 2013 at 10:16 AM.
Reason: [CLOSED]