function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
roktechieroktechie 

Hosted javascript frameworks

I am curious which javascript frameworks are hosted on Salesforce servers.  I have found dojo, which I am currently using, but I am very interested in using Mochikit and/or Scriptaculous.  Are either of these currently hosted on SF's servers?  If not, could they be?
cheenathcheenath
The latest version of dojo is hosted on salesforce.com. You can find it at

/js/dojo/0.4.1/dojo.js

Other toolkits are not hosted.



roktechieroktechie
Thanks for the info.  I will just have to cross-domain load my js libs from another server I suppose.

Also, 0.4.2 is the latest stable dojo release.  They fixed quite a few bugs. 

http://trac.dojotoolkit.org/query?status=closed&milestone=0.4.2&order=priority

How can I request the framework to be updated?
Ron HessRon Hess
You can also load your JS (framework) files up to salesforce as a "S-Control Snippet", then include this in other scontrols.

That way salesforce is still serving your framework, you can even put dojo-0.4.2 into a snippet if that is what you require, i usualy package up only the files/functiosn needed, put them into one file ( prehaps JS compiled) then load that into a snippet.
vpcvpc

Hi Ron,

How do you store the framework files ? Are they stored as documents ?

If so, how do you reference them ?

 

Cheers,

 

Val.

roktechieroktechie

I stored them as S-Control snippets, then referenced them like this.

 

Code:

<script type="text/javascript" src="/servlet/servlet.Integration—lid=[ID]"></script>


 

Where [ID] is the id of that snippet in the URL bar of your browser after saving the snippet (the id of the snippet).
roktechieroktechie
I forgot to mention, you will probably want to get a packed (single file) version of whatever JS framework you want to use, just to avoid having to create multiple snippets and include each of them.
jduleyjduley
I posted a question about when 0.4.3 will be hosted but this sounds like another option for me.  How do I go about packaging all of dojo into a single file? 
ppatppat
Jduley,

Are you pack all the dojo files ? how do you reference once they are packed in to one file (Assuming you are able to pack)

Thanks for the response.




Message Edited by ppat on 03-29-2008 06:42 PM