reactive_rails_generator 0.1.0 → 0.1.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c670c4b33f14daa908bb101784813d83d513adc8
4
- data.tar.gz: 52b100d8fd125f8aaaa761d622b543a6ddaec17e
3
+ metadata.gz: 5803d719ad896dccda1b87c1441f2ad1e40fb54f
4
+ data.tar.gz: 061cf172fe62ff09ca194e2e6dc23eee88ed02a2
5
5
  SHA512:
6
- metadata.gz: 9e23abb5ea7e1f92ff1e0c40ec90e0b0efda77f6f145baeb8a0bc885c42e91336913d0927a52622edf74b97134463f70635e6fef4c368182d9f5d0d40aa91fe2
7
- data.tar.gz: 733070925fcd826ef5680d7abbec2edb840810922ac153a4f75bac303f2ced0f5beba299440ff7ed958b939b16aef5e2aeeb7f7685c85e79aa234c33aa3a300e
6
+ metadata.gz: e4233b04f162f3dec69ad777a99320dace76dc08a4fb496dec3d01c6e5823c7de3639ac4a31cb8ebcd111389f6bc644a55b49050079ff14962ee1fbd7e557f08
7
+ data.tar.gz: 4284a31879ea6b7ba9c0a252310e76a6bd993af80e2bbd1abd327a3cdecc67a4c4fe3c9024b9376559839692d44abf373ea5431eed2eb031161b7367d742008f
@@ -10,7 +10,7 @@ module Reactrb
10
10
  @modules = component_array[0..-2]
11
11
  @file_name = component_array.last
12
12
  @indet = 1
13
- template "component_template.rb", File.join('app/react/components', @modules.join("/"), "#{@file_name.underscore}.rb")
13
+ template "component_template.rb", File.join('app/react/components', @modules.map(&:downcase).join("/"), "#{@file_name.underscore}.rb")
14
14
  end
15
15
  end
16
16
 
@@ -52,6 +52,11 @@ require_tree './models'
52
52
  end
53
53
  end
54
54
 
55
+ def add_config
56
+ application "config.assets.paths << ::Rails.root.join('app', 'react').to_s"
57
+ application 'config.autoload_paths += %W(#{config.root}/app/react/models)' if options[:"reactive-record"] || options[:all]
58
+ end
59
+
55
60
  def add_gems
56
61
  gem 'reactive-ruby'
57
62
  gem 'react-rails', '~> 1.3.0'
@@ -59,7 +64,6 @@ require_tree './models'
59
64
  gem 'therubyracer', platforms: :ruby
60
65
 
61
66
  # optional gems
62
- gem 'opal-jquery' if options[:"opal-jquery"] || options[:all]
63
67
  gem 'reactive-router' if options[:"reactive-router"] || options[:all]
64
68
  gem 'reactive-record' if options[:"reactive-record"] || options[:all]
65
69
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: reactive_rails_generator
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Loic Boutet