Skip to content

matthuhiggins/googtaculous

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Googtaculous
============

Modifies how javascript_include_tag works, so that Rails javascript files are served from Google's Ajax Library API.
Local javascript is used when ActionController::Base.consider_all_requests_local is true, which is true in development mode.

Example
=======

<%= javascript_include_tag 'prototype', 'effects' %>

Expands to:

<script src="http://ajax.googleapis.com/ajax/libs/prototype/1.6.0.3/prototype.js" type="text/javascript"></script>
<script src="http://ajax.googleapis.com/ajax/libs/scriptaculous/1.8.2/effects.js" type="text/javascript"></script>


Additionally,

<%= javascript_include_tag :defaults %>

expands to 

<script src="http://ajax.googleapis.com/ajax/libs/prototype/1.6.0.3/prototype.js" type="text/javascript"></script>
<script src="http://ajax.googleapis.com/ajax/libs/scriptaculous/1.8.2/effects.js" type="text/javascript"></script>
<script src="http://ajax.googleapis.com/ajax/libs/scriptaculous/1.8.2/dragdrop.js" type="text/javascript"></script>
<script src="http://ajax.googleapis.com/ajax/libs/scriptaculous/1.8.2/controls.js" type="text/javascript"></script>
<script src="/javascripts/application.js?1213130636" type="text/javascript"></script>


Copyright (c) 2008 [Matthew Higgins], released under the MIT license

About

Modify javascript_include_tag to use google's Ajax Library Api

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages