Javascript Architecture

Jun 29, 2009 at 7:59 PM
Edited Jun 30, 2009 at 9:57 PM

How should we approach Javascript in this project?

The problem is that the Microsoft Ajax Scripts innitial load cost is over 100k in bandwidth. JQuery is under 100 for basic but it is still approximately an addtional 100K.
With Images, Html, Javscript a single page can quickly exceed 1/2 Megabyte!
I love jQuery for MVC because it is the only library loaded and it is the deault.
Embedding jQuery in a redistributable DLL would maked versining a problem. So you can not realy embed it. If you use it you have to tell people to go download jQuery before the "out of the box" product will work.
It does not seem to be worth it to deal with any of this for a custom control. It seems more logical to write it from scratch and not have to worry about external libraries at all. Custom javscript based around the need in the custom contols can then be managed internily with no worry about 3rd party changes or addtioonal overhead.
In conclusion...
As much as I like it as a primary framework or for a website or with MVC, I do not think custom controls should use it. I am hesistent to use it side by side Micosoft Ajax because of overhead.

I want this project to work out of the box with no external libraries and with or without Microsoft Ajax.