This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
merb-plugins / merb_jquery
| name | age | message | |
|---|---|---|---|
| .. | |||
| |
LICENSE | Fri Dec 12 16:15:52 -0800 2008 | |
| |
README | Fri Dec 12 16:15:54 -0800 2008 | |
| |
Rakefile | Fri Dec 12 16:15:54 -0800 2008 | |
| |
TODO | Fri Dec 12 16:15:52 -0800 2008 | |
| |
lib/ | Fri Dec 12 16:15:53 -0800 2008 |
merb_jquery/README
merb-jquery
===========
Makes it easy to use jQuery in your application.
$ gem install merb_jquery
Add
require 'merb_jquery'
to your init.rb
$ rake merb:jquery:install
Installs the latest jQuery to public/javascripts
In your layout, inside <head>:
<%= jquery %>
In your views:
<% jquery do %>
$('#foo').something();
<% end %>
jquery is a helper method is a shortcut to
throw_content :for_query and catch_content :for_jquery
You still need to inlude jQuery javascript file manually, for instance,
using merb-assets:
# in init.rb
dependency "merb-assets", "0.9.10"
# in Erb layout
<%= js_include_tag "jquery" %>
# or in Haml layout
= js_include_tag "jquery"






