rbjs 0.10.5 → 0.10.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
1
  ActionView::Helpers::RenderingHelper.module_eval do
2
2
  def render_with_js(options = {}, locals = {}, &block)
3
3
  if options == :js
4
- Rbjs::Root.new(self, &block).evaluate
4
+ Rbjs::Root.new(self.view_context, &block).evaluate
5
5
  else
6
6
  render_without_js(options, locals, &block)
7
7
  end
@@ -21,4 +21,13 @@ module Rbjs
21
21
  end
22
22
  end
23
23
 
24
+ module Rbjs
25
+ class Root
26
+ # make respond_to?(:render) return true.
27
+ def render(options = {}, locals = {}, &block)
28
+ view_context.render(options, locals, &block)
29
+ end
30
+ end
31
+ end
32
+
24
33
  ActionView::Template.register_template_handler :rbjs, Rbjs::TemplateHandler.new
@@ -1,3 +1,3 @@
1
1
  module Rbjs
2
- VERSION = "0.10.5"
2
+ VERSION = "0.10.6"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rbjs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.5
4
+ version: 0.10.6
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-04-21 00:00:00.000000000 Z
12
+ date: 2012-04-22 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: json
16
- requirement: &6898800 !ruby/object:Gem::Requirement
16
+ requirement: &5692600 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,7 +21,7 @@ dependencies:
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *6898800
24
+ version_requirements: *5692600
25
25
  description: Remote Javascript Builder for Ruby on Rails
26
26
  email:
27
27
  - buhrmi@gmail.com