hyper-react 0.12.7 → 0.99.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (129) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +48 -34
  3. data/CODE_OF_CONDUCT.md +49 -0
  4. data/Gemfile +5 -6
  5. data/README.md +47 -98
  6. data/Rakefile +6 -28
  7. data/hyper-react.gemspec +36 -43
  8. data/lib/hyper-react.rb +4 -73
  9. data/lib/react/version.rb +3 -0
  10. metadata +91 -249
  11. data/.codeclimate.yml +0 -27
  12. data/.rubocop.yml +0 -1159
  13. data/.travis.yml +0 -62
  14. data/Appraisals +0 -31
  15. data/CHANGELOG.md +0 -143
  16. data/LICENSE +0 -19
  17. data/UPGRADING.md +0 -24
  18. data/component-name-lookup.md +0 -145
  19. data/config.ru +0 -26
  20. data/gemfiles/opal_0.10_react_13.gemfile +0 -15
  21. data/gemfiles/opal_0.10_react_14.gemfile +0 -15
  22. data/gemfiles/opal_0.10_react_15.gemfile +0 -15
  23. data/gemfiles/opal_0.8_react_13.gemfile +0 -15
  24. data/gemfiles/opal_0.8_react_14.gemfile +0 -15
  25. data/gemfiles/opal_0.8_react_15.gemfile +0 -15
  26. data/gemfiles/opal_0.9_react_13.gemfile +0 -15
  27. data/gemfiles/opal_0.9_react_14.gemfile +0 -15
  28. data/gemfiles/opal_0.9_react_15.gemfile +0 -15
  29. data/gemfiles/opal_master_react_15.gemfile +0 -16
  30. data/lib/generators/reactive_ruby/test_app/templates/assets/javascripts/components.rb +0 -3
  31. data/lib/generators/reactive_ruby/test_app/templates/assets/javascripts/test_application.rb +0 -2
  32. data/lib/generators/reactive_ruby/test_app/templates/boot.rb.erb +0 -6
  33. data/lib/generators/reactive_ruby/test_app/templates/script/rails +0 -5
  34. data/lib/generators/reactive_ruby/test_app/templates/test_application.rb.erb +0 -13
  35. data/lib/generators/reactive_ruby/test_app/templates/views/components/hello_world.rb +0 -11
  36. data/lib/generators/reactive_ruby/test_app/templates/views/components/todo.rb +0 -14
  37. data/lib/generators/reactive_ruby/test_app/templates/views/layouts/test_layout.html.erb +0 -0
  38. data/lib/generators/reactive_ruby/test_app/test_app_generator.rb +0 -111
  39. data/lib/rails-helpers/top_level_rails_component.rb +0 -54
  40. data/lib/react-sources/react-server.js +0 -2
  41. data/lib/react/api.rb +0 -173
  42. data/lib/react/callbacks.rb +0 -41
  43. data/lib/react/children.rb +0 -30
  44. data/lib/react/component.rb +0 -168
  45. data/lib/react/component/api.rb +0 -50
  46. data/lib/react/component/base.rb +0 -13
  47. data/lib/react/component/class_methods.rb +0 -189
  48. data/lib/react/component/dsl_instance_methods.rb +0 -23
  49. data/lib/react/component/params.rb +0 -6
  50. data/lib/react/component/props_wrapper.rb +0 -78
  51. data/lib/react/component/should_component_update.rb +0 -94
  52. data/lib/react/component/tags.rb +0 -129
  53. data/lib/react/config.rb +0 -5
  54. data/lib/react/config/client.rb.erb +0 -19
  55. data/lib/react/config/server.rb +0 -23
  56. data/lib/react/element.rb +0 -169
  57. data/lib/react/event.rb +0 -76
  58. data/lib/react/ext/hash.rb +0 -9
  59. data/lib/react/ext/opal-jquery/element.rb +0 -26
  60. data/lib/react/ext/string.rb +0 -8
  61. data/lib/react/hash.rb +0 -13
  62. data/lib/react/native_library.rb +0 -87
  63. data/lib/react/object.rb +0 -15
  64. data/lib/react/react-source-browser.rb +0 -3
  65. data/lib/react/react-source-server.rb +0 -3
  66. data/lib/react/react-source.rb +0 -20
  67. data/lib/react/ref_callback.rb +0 -31
  68. data/lib/react/rendering_context.rb +0 -144
  69. data/lib/react/server.rb +0 -23
  70. data/lib/react/state_wrapper.rb +0 -23
  71. data/lib/react/test.rb +0 -16
  72. data/lib/react/test/dsl.rb +0 -17
  73. data/lib/react/test/matchers/render_html_matcher.rb +0 -56
  74. data/lib/react/test/rspec.rb +0 -15
  75. data/lib/react/test/session.rb +0 -37
  76. data/lib/react/test/utils.rb +0 -25
  77. data/lib/react/top_level.rb +0 -118
  78. data/lib/react/top_level_render.rb +0 -29
  79. data/lib/react/validator.rb +0 -136
  80. data/lib/reactive-ruby/component_loader.rb +0 -50
  81. data/lib/reactive-ruby/isomorphic_helpers.rb +0 -212
  82. data/lib/reactive-ruby/rails.rb +0 -7
  83. data/lib/reactive-ruby/rails/component_mount.rb +0 -46
  84. data/lib/reactive-ruby/rails/controller_helper.rb +0 -15
  85. data/lib/reactive-ruby/rails/railtie.rb +0 -33
  86. data/lib/reactive-ruby/serializers.rb +0 -15
  87. data/lib/reactive-ruby/server_rendering/contextual_renderer.rb +0 -42
  88. data/lib/reactive-ruby/version.rb +0 -3
  89. data/lib/reactrb/auto-import.rb +0 -27
  90. data/lib/reactrb/deep-compare.rb +0 -24
  91. data/lib/reactrb/new-event-name-convention.rb +0 -11
  92. data/logo1.png +0 -0
  93. data/logo2.png +0 -0
  94. data/logo3.png +0 -0
  95. data/path_release_steps.md +0 -9
  96. data/spec/controller_helper_spec.rb +0 -34
  97. data/spec/index.html.erb +0 -11
  98. data/spec/react/callbacks_spec.rb +0 -138
  99. data/spec/react/children_spec.rb +0 -76
  100. data/spec/react/component/base_spec.rb +0 -32
  101. data/spec/react/component_spec.rb +0 -884
  102. data/spec/react/dsl_spec.rb +0 -303
  103. data/spec/react/element_spec.rb +0 -136
  104. data/spec/react/event_spec.rb +0 -24
  105. data/spec/react/native_library_spec.rb +0 -322
  106. data/spec/react/observable_spec.rb +0 -42
  107. data/spec/react/opal_jquery_extensions_spec.rb +0 -68
  108. data/spec/react/param_declaration_spec.rb +0 -269
  109. data/spec/react/react_spec.rb +0 -215
  110. data/spec/react/refs_callback_spec.rb +0 -56
  111. data/spec/react/server_spec.rb +0 -25
  112. data/spec/react/state_spec.rb +0 -55
  113. data/spec/react/test/dsl_spec.rb +0 -43
  114. data/spec/react/test/matchers/render_html_matcher_spec.rb +0 -83
  115. data/spec/react/test/rspec_spec.rb +0 -62
  116. data/spec/react/test/session_spec.rb +0 -88
  117. data/spec/react/test/utils_spec.rb +0 -28
  118. data/spec/react/top_level_component_spec.rb +0 -101
  119. data/spec/react/tutorial/tutorial_spec.rb +0 -36
  120. data/spec/react/validator_spec.rb +0 -124
  121. data/spec/reactive-ruby/component_loader_spec.rb +0 -77
  122. data/spec/reactive-ruby/isomorphic_helpers_spec.rb +0 -160
  123. data/spec/reactive-ruby/rails/asset_pipeline_spec.rb +0 -10
  124. data/spec/reactive-ruby/rails/component_mount_spec.rb +0 -66
  125. data/spec/reactive-ruby/server_rendering/contextual_renderer_spec.rb +0 -35
  126. data/spec/spec_helper.rb +0 -149
  127. data/spec/support/react/spec_helpers.rb +0 -44
  128. data/spec/vendor/es5-shim.min.js +0 -6
  129. data/spec/vendor/jquery-2.2.4.min.js +0 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 44aee5bb00f9e340cd5d892e7f2a38e38bc0d1d3
4
- data.tar.gz: 6ca48472eec183e3c32300cd218234645f113fa6
2
+ SHA256:
3
+ metadata.gz: 1015888c1b0bf9c06d4ab1a7aa15f92108e662b6a6176ddfe1ad1b9bc90cef32
4
+ data.tar.gz: 53f593db95bc32895aaeacb2acf6739ae483fa7baf0c446073d8ade78f7ec206
5
5
  SHA512:
6
- metadata.gz: 2d52361feb3a174d2453ea0f098e31ab8d04f03a06235ecdbca94fb9b9f0e1502c92cd2bd524fa688394e085240313c11535bef673afa9aae3f0a04264fa694f
7
- data.tar.gz: 195be570e47647c4b058989be793a08b55712a2f90896116b503b60dc620239feabd15e5181016f51533f274e50b1d78d5da7cd9986017297883ba4f6a6cf79e
6
+ metadata.gz: 80948f32af7f20b3f230d09a1cc8dafed8a39d0b15124d445077482b46f419a56cebc9fe3d49fce384801e9eef4ba3855bdcd7f2ba77030cd0a27524ab217df0
7
+ data.tar.gz: 7d086b04cbd5c2e21fbc9989962e9a0679071d08b607698d04d3fb4a1271e13226285783c9ced385fb86300880baa64a81911db63097acb49c6cad6fce9fb895
data/.gitignore CHANGED
@@ -1,36 +1,50 @@
1
- # Logs
2
- logs
3
- *.log
4
-
5
- # Runtime data
6
- pids
7
- *.pid
8
- *.seed
9
-
10
- # Directory for instrumented libs generated by jscoverage/JSCover
11
- lib-cov
12
-
13
- # Coverage directory used by tools like istanbul
14
- coverage
15
-
16
- # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
17
- .grunt
18
-
19
- # node-waf configuration
20
- .lock-wscript
21
-
22
- # Compiled binary addons (http://nodejs.org/api/addons.html)
23
- build/Release
24
-
25
- # Dependency directory
26
- # https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git-
27
- node_modules
28
-
29
- # Ignore bundler config.
30
- .bundle
31
-
32
- spec/test_app
1
+ *.rbc
2
+ capybara-*.html
3
+ .rspec
4
+ /log
5
+ /tmp
6
+ /db/*.sqlite3
7
+ /db/*.sqlite3-journal
8
+ /public/system
9
+ /coverage/
10
+ /spec/tmp
11
+ **.orig
12
+ rerun.txt
13
+ pickle-email-*.html
14
+
15
+ # TODO Comment out these rules if you are OK with secrets being uploaded to the repo
16
+ config/initializers/secret_token.rb
17
+ config/secrets.yml
18
+
19
+ # dotenv
20
+ # TODO Comment out this rule if environment variables can be committed
21
+ .env
22
+
23
+ ## Environment normalization:
24
+ /.bundle
25
+ /vendor/bundle
26
+
27
+ # these should all be checked in to normalize the environment:
28
+ # Gemfile.lock, .ruby-version, .ruby-gemset
29
+
30
+ # unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
31
+ .rvmrc
32
+
33
+ # if using bower-rails ignore default bower_components path bower.json files
34
+ /vendor/assets/bower_components
35
+ *.bowerrc
36
+ bower.json
37
+
38
+ # Ignore pow environment settings
39
+ .powenv
40
+
41
+ # Ignore Byebug command history file.
42
+ .byebug_history
43
+
44
+ # ignore gems
45
+ *.gem
33
46
  Gemfile.lock
34
47
 
35
- /gemfiles/*.lock
36
- /tmp
48
+ # ignore Idea
49
+ .idea
50
+ .vscode
@@ -0,0 +1,49 @@
1
+ # Contributor Code of Conduct
2
+
3
+ As contributors and maintainers of this project, and in the interest of
4
+ fostering an open and welcoming community, we pledge to respect all people who
5
+ contribute through reporting issues, posting feature requests, updating
6
+ documentation, submitting pull requests or patches, and other activities.
7
+
8
+ We are committed to making participation in this project a harassment-free
9
+ experience for everyone, regardless of level of experience, gender, gender
10
+ identity and expression, sexual orientation, disability, personal appearance,
11
+ body size, race, ethnicity, age, religion, or nationality.
12
+
13
+ Examples of unacceptable behavior by participants include:
14
+
15
+ * The use of sexualized language or imagery
16
+ * Personal attacks
17
+ * Trolling or insulting/derogatory comments
18
+ * Public or private harassment
19
+ * Publishing other's private information, such as physical or electronic
20
+ addresses, without explicit permission
21
+ * Other unethical or unprofessional conduct
22
+
23
+ Project maintainers have the right and responsibility to remove, edit, or
24
+ reject comments, commits, code, wiki edits, issues, and other contributions
25
+ that are not aligned to this Code of Conduct, or to ban temporarily or
26
+ permanently any contributor for other behaviors that they deem inappropriate,
27
+ threatening, offensive, or harmful.
28
+
29
+ By adopting this Code of Conduct, project maintainers commit themselves to
30
+ fairly and consistently applying these principles to every aspect of managing
31
+ this project. Project maintainers who do not follow or enforce the Code of
32
+ Conduct may be permanently removed from the project team.
33
+
34
+ This code of conduct applies both within project spaces and in public spaces
35
+ when an individual is representing the project or its community.
36
+
37
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
38
+ reported by contacting a project maintainer at mitch@catprint.com. All
39
+ complaints will be reviewed and investigated and will result in a response that
40
+ is deemed necessary and appropriate to the circumstances. Maintainers are
41
+ obligated to maintain confidentiality with regard to the reporter of an
42
+ incident.
43
+
44
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage],
45
+ version 1.3.0, available at
46
+ [http://contributor-covenant.org/version/1/3/0/][version]
47
+
48
+ [homepage]: http://contributor-covenant.org
49
+ [version]: http://contributor-covenant.org/version/1/3/0/
data/Gemfile CHANGED
@@ -1,8 +1,7 @@
1
1
  source 'https://rubygems.org'
2
+ #gem "opal-jquery", git: "https://github.com/opal/opal-jquery.git", branch: "master"
3
+ gem 'hyper-spec', path: '../hyper-spec'
4
+ gem 'hyperloop-config', path: '../hyperloop-config'
5
+ gem 'hyper-store', path: '../hyper-store'
6
+ gem 'hyper-component', path: '../hyper-component'
2
7
  gemspec
3
-
4
- ruby ">= 1.9.3"
5
-
6
- group :development do
7
- gem "appraisal"
8
- end
data/README.md CHANGED
@@ -1,128 +1,77 @@
1
- # hyper-react
1
+ <div class="githubhyperloopheader">
2
2
 
3
- [![Join the chat at https://gitter.im/reactrb/chat](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/reactrb/chat?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
4
- [![Build Status](https://travis-ci.org/ruby-hyperloop/hyper-react.svg?branch=master)](https://travis-ci.org/ruby-hyperloop/hyper-react)
5
- [![Code Climate](https://codeclimate.com/github/reactrb/reactrb/badges/gpa.svg)](https://codeclimate.com/github/reactrb/reactrb)
6
- [![Gem Version](https://badge.fury.io/rb/hyper-react.svg)](https://badge.fury.io/rb/hyper-react)
3
+ <p align="center">
7
4
 
8
- **hyper-react is an [Opal Ruby](http://opalrb.org) wrapper of
9
- [React.js library](https://facebook.github.io/react)**.
5
+ <a href="http://ruby-hyperloop.org/" alt="Hyperloop" title="Hyperloop">
6
+ <img width="350px" src="http://ruby-hyperloop.org/images/hyperloop-github-logo.png">
7
+ </a>
10
8
 
11
- It lets you write reactive UI components, with Ruby's elegance using the tried
12
- and true React.js engine. :heart:
9
+ </p>
13
10
 
14
- Visit [ruby-hyperloop.io](http://ruby-hyperloop.io) for the full story.
11
+ <h2 align="center">The Complete Isomorphic Ruby Framework</h2>
15
12
 
16
- ### Important: `react.rb`, `reactive-ruby` and `reactrb` gems are **deprecated**. See [**UPGRADING**](UPGRADING.md) for details.
13
+ <br>
17
14
 
18
- ## Installation
15
+ <a href="http://ruby-hyperloop.org/" alt="Hyperloop" title="Hyperloop">
16
+ <img src="http://ruby-hyperloop.org/images/githubhyperloopbadge.png">
17
+ </a>
19
18
 
20
- Install the gem, or load the js library
19
+ <a href="https://gitter.im/ruby-hyperloop/chat" alt="Gitter chat" title="Gitter chat">
20
+ <img src="http://ruby-hyperloop.org/images/githubgitterbadge.png">
21
+ </a>
21
22
 
22
- 1. Add `gem 'hyper-react'` to your **Gemfile**
23
- 2. Or `gem install hyper-react`
24
- 3. Or install (or load via cdn) from [reactrb-express.js](http://github.com/ruby-hyperloop/reactrb-express)
23
+ [![Gem Version](https://badge.fury.io/rb/hyper-component.svg)](https://badge.fury.io/rb/hyper-component)
25
24
 
26
- For gem installation it is highly recommended to read the [getting started](http://ruby-hyperloop.io/get_started/) and [installation](http://ruby-hyperloop.io/installation/) guides at [ruby-hyperloop.io.](http://ruby-hyperloop.io)
25
+ <p align="center">
26
+ <img src="http://ruby-hyperloop.org/images/HyperComponents.png" width="100" alt="Hyper-components">
27
+ </p>
27
28
 
28
- ## Quick Overview
29
+ </div>
29
30
 
30
- A component is a plain ruby class with a `#render` method defined.
31
+ ## Hyper-Component GEM is part of Hyperloop GEMS family
31
32
 
32
- ```ruby
33
- class HelloMessage
34
- def render
35
- React.create_element("div") { "Hello World!" }
36
- end
37
- end
38
-
39
- puts React.render_to_static_markup(React.create_element(HelloMessage))
33
+ Build interactive Web applications quickly. Hyperloop encourages rapid development with clean, pragmatic design. With developer productivity as our highest goal, Hyperloop takes care of much of the hassle of Web development, so you can focus on innovation and delivering end-user value.
40
34
 
41
- # => '<div>Hello World!</div>'
42
- ```
35
+ One language. One model. One set of tests. The same business logic and domain models running on the clients and the server. Hyperloop is fully integrated with Rails and also gives you unfettered access to the complete universe of JavaScript libraries (including React) from within your Ruby code. Hyperloop lets you build beautiful interactive user interfaces in Ruby.
43
36
 
44
- ### React::Component
37
+ Everything has a place in our architecture. Components deliver interactive user experiences, Operations encapsulate business logic, Models magically synchronize data between clients and servers, Policies govern authorization and Stores hold local state.
45
38
 
46
- You can simply include `React::Component` to get the power of a complete DSL to generate html markup, event handlers and it also provides a full set of class macros to define states, parameters, and lifecycle callbacks.
39
+ **Hyper-component** brings Components modules uesed in the Hyperloop interface.
47
40
 
48
- As events occur, components update their state, which causes them to rerender, and perhaps pass new parameters to lower level components, thus causing them to rerender.
41
+ ## Getting Started
49
42
 
43
+ 1. Update your Gemfile:
44
+
50
45
  ```ruby
51
- require 'opal'
52
- require 'browser/interval'
53
- require 'opal-jquery'
54
- require 'react/react-source'
55
- require 'hyper-react'
56
- require 'react/top_level_render'
57
-
58
- class HelloWorld < React::Component::Base
59
- param :time, type: Time
60
- render do
61
- p do
62
- span { "Hello, " }
63
- input(type: :text, placeholder: "Your Name Here")
64
- span { "! It is #{params.time}"}
65
- end
66
- end
67
- end
68
-
69
- every(1) do
70
- Element["#example"].render do
71
- HelloWorld(time: Time.now)
72
- end
73
- end
74
- ```
75
-
76
- hyper-react components are *isomorphic* (or *univeral*) meaning they can run on the server as well as the client.
77
-
78
- hyper-react integrates well with Rails, Sinatra, and simple static sites, and can be added to existing web pages very easily.
79
-
80
- Under the hood the actual work is effeciently done by the [React.js](https://facebook.github.io/react) engine.
81
-
82
-
83
- ## Why ?
46
+ #Gemfile
84
47
 
85
- + *Single Language:* Use Ruby everywhere, no JS, markup languages, or JSX
86
- + *Powerful DSL:* Describe HTML and event handlers with a minimum of fuss
87
- + *Ruby Goodness:* Use all the features of Ruby to create reusable, maintainable UI code
88
- + *React Simplicity:* Nothing is taken away from the React.js model
89
- + *Enhanced Features:* Enhanced parameter and state management and other new features
90
- + *Plays well with Others:* Works with other frameworks, React.js components, Rails, Sinatra and static web pages
91
-
92
- ## Problems, Questions, Issues
93
-
94
- + [Stack Overflow](http://stackoverflow.com/questions/tagged/react.rb) tag `react.rb` for specific problems.
95
- + [Gitter.im](https://gitter.im/reactrb/chat) for general questions, discussion, and interactive help.
96
- + [Github Issues](https://github.com/reactrb/reactrb/issues) for bugs, feature enhancements, etc.
97
-
98
-
99
- ## Roadmap
100
-
101
- Version 0.10.x **will not be** 100% backward compatible with 0.3.0 (`react.rb`) or 0.7.x (`reactive-ruby`).
102
-
103
- Please let us know either at [Gitter.im](https://gitter.im/reactrb/chat) or [via an issue](https://github.com/reactrb/reactrb/issues) if you have specific concerns with the upgrade from 0.3.0 to 0.10.x.
104
-
105
- ## Developing
48
+ gem 'hyperloop'
49
+ ```
106
50
 
107
- `git clone` the project.
51
+ 2. At the command prompt, update your bundle :
108
52
 
109
- To play with some live examples, refer to https://github.com/ruby-hyperloop/reactrb-examples.
53
+ $ bundle update
110
54
 
111
- Note that these are very simple examples, for the purpose of showing how to configure the gem in various server environments. For more examples and information see [ruby-hyperloop.io.](http://ruby-hyperloop.io)
55
+ 3. Run the hyperloop install generator:
112
56
 
113
- ## Testing
57
+ $ rails g hyperloop:install
114
58
 
115
- 1. Run `bundle exec rake test_app` to generate a dummy test app.
116
- 2. `bundle exec appraisal install` to generate separate gemfiles for different environments.
117
- 2. `bundle exec appraisal opal-0.10-react-15 rake` to run test for opal-0.10 & react-v0.15.
59
+ 4. Follow the guidelines to start developing your application. You may find
60
+ the following resources handy:
61
+ * [Getting Started with Hyperloop](http://ruby-hyperloop.org/start/components/)
62
+ * [Hyperloop Guides](http://ruby-hyperloop.org/docs/architecture)
63
+ * [Hyperloop Tutorial](http://ruby-hyperloop.org/tutorials)
118
64
 
119
- ## Contributions
65
+ ## Community
120
66
 
121
- This project is still in early stage, so discussion, bug reports and PRs are
122
- really welcome :wink:.
67
+ #### Getting Help
68
+ Please **do not post** usage questions to GitHub Issues. For these types of questions use our [Gitter chatroom](https://gitter.im/ruby-hyperloop/chat) or [StackOverflow](http://stackoverflow.com/questions/tagged/hyperloop).
123
69
 
70
+ #### Submitting Bugs and Enhancements
71
+ [GitHub Issues](https://github.com/ruby-hyperloop/hyperloop/issues) is for suggesting enhancements and reporting bugs. Before submiting a bug make sure you do the following:
72
+ * Check out our [contributing guide](https://github.com/ruby-hyperloop/hyperloop/blob/master/CONTRIBUTING.md) for info on our release cycle.
124
73
 
125
74
  ## License
126
75
 
127
- In short, hyper-react is available under the MIT license. See the LICENSE file for
128
- more info.
76
+ Hyperloop is released under the [MIT License](http://www.opensource.org/licenses/MIT).
77
+
data/Rakefile CHANGED
@@ -1,33 +1,11 @@
1
- require 'bundler'
2
- Bundler.require
3
- Bundler::GemHelper.install_tasks
4
-
5
- # Store the BUNDLE_GEMFILE env, since rake or rspec seems to clean it
6
- # while invoking task.
7
- ENV['REAL_BUNDLE_GEMFILE'] = ENV['BUNDLE_GEMFILE']
8
-
1
+ require 'bundler/gem_tasks'
9
2
  require 'rspec/core/rake_task'
10
- require 'opal/rspec/rake_task'
11
-
12
- RSpec::Core::RakeTask.new('ruby:rspec')
13
3
 
14
- Opal::RSpec::RakeTask.new('opal:rspec') do |s, task|
15
- s.append_path 'spec/vendor'
16
- s.index_path = 'spec/index.html.erb'
17
- task.timeout = 80000 if task
18
- end
19
-
20
- task :test do
21
- Rake::Task['ruby:rspec'].invoke
22
- Rake::Task['opal:rspec'].invoke
23
- end
4
+ RSpec::Core::RakeTask.new(:spec)
24
5
 
25
- require 'generators/reactive_ruby/test_app/test_app_generator'
26
- desc "Generates a dummy app for testing"
27
- task :test_app do
28
- ReactiveRuby::TestAppGenerator.start
29
- puts "Setting up test app database..."
30
- system("bundle exec rake db:drop db:create db:migrate > #{File::NULL}")
6
+ namespace :spec do
7
+ task :prepare do
8
+ end
31
9
  end
32
10
 
33
- task default: [ :test ]
11
+ task default: :spec
@@ -1,48 +1,41 @@
1
- # -*- encoding: utf-8 -*-
2
- $:.push File.expand_path('../lib/', __FILE__)
1
+ lib = File.expand_path('../lib', __FILE__)
2
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
+ require 'react/version'
3
4
 
4
- require 'reactive-ruby/version'
5
+ Gem::Specification.new do |spec|
6
+ spec.name = 'hyper-react'
7
+ spec.version = React::VERSION
8
+ spec.authors = ['Mitch VanDuyn', 'Jan Biedermann']
9
+ spec.email = ['mitch@catprint.com', 'jan@kursator.com']
10
+ spec.summary = 'Write advanced React components in Ruby.'
11
+ spec.homepage = 'http://ruby-hyperloop.org'
12
+ spec.license = 'MIT'
13
+ # spec.metadata = {
14
+ # "homepage_uri" => 'http://ruby-hyperloop.org',
15
+ # "source_code_uri" => 'https://github.com/ruby-hyperloop/hyper-component'
16
+ # }
5
17
 
6
- Gem::Specification.new do |s|
7
- s.name = 'hyper-react'
8
- s.version = React::VERSION
18
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(spec)/}) }
19
+ spec.bindir = 'exe'
20
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
21
+ spec.require_paths = ['lib']
9
22
 
10
- s.authors = ['David Chang', 'Adam Jahn', 'Mitch VanDuyn']
11
- s.email = 'reactrb@catprint.com'
12
- s.homepage = 'http://ruby-hyperloop.io/gems/reactrb/'
13
- s.summary = 'Opal Ruby wrapper of React.js library.'
14
- s.license = 'MIT'
15
- s.description = "Write React UI components in pure Ruby."
16
- s.files = `git ls-files`.split("\n")
17
- s.executables = `git ls-files -- bin/*`.split("\n").map { |f| File.basename(f) }
18
- s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
19
- s.require_paths = ['lib']
23
+ spec.add_dependency 'actionview', '>= 4.0.0'
20
24
 
21
- s.add_dependency 'opal', '>= 0.8.0'
22
- s.add_dependency 'opal-activesupport', '>= 0.2.0'
23
- s.add_dependency 'hyper-store', '>= 0.2.1'
24
- s.add_dependency 'hyperloop-config', '>= 0.9.7'
25
- s.add_development_dependency 'rake', '< 11.0'
26
- s.add_development_dependency 'rspec-rails', '3.3.3'
27
- s.add_development_dependency 'timecop'
28
- s.add_development_dependency 'opal-rspec'
29
- s.add_development_dependency 'sinatra'
30
- s.add_development_dependency 'opal-jquery'
31
-
32
- # For Test Rails App
33
- s.add_development_dependency 'rails', '4.2.4'
34
- s.add_development_dependency 'mime-types', '< 3'
35
- s.add_development_dependency 'opal-rails'
36
- s.add_development_dependency 'react-rails', '<= 1.10.0'
37
-
38
- s.add_development_dependency 'nokogiri', '< 1.7'
39
- s.add_development_dependency 'rubocop'
40
- if RUBY_PLATFORM == 'java'
41
- s.add_development_dependency 'jdbc-sqlite3'
42
- s.add_development_dependency 'activerecord-jdbcsqlite3-adapter'
43
- s.add_development_dependency 'therubyrhino'
44
- else
45
- s.add_development_dependency 'sqlite3', '1.3.10'
46
- s.add_development_dependency 'therubyracer', '0.12.2'
47
- end
25
+ spec.add_dependency 'hyper-component', React::VERSION
26
+ spec.add_development_dependency 'bundler'
27
+ spec.add_development_dependency 'chromedriver-helper'
28
+ spec.add_development_dependency 'hyper-spec', React::VERSION
29
+ spec.add_development_dependency 'listen'
30
+ spec.add_development_dependency 'mini_racer', '~> 0.1.15'
31
+ spec.add_development_dependency 'opal', '>= 0.11.0', '< 0.12.0'
32
+ spec.add_development_dependency 'opal-browser', '~> 0.2.0'
33
+ spec.add_development_dependency 'opal-rails', '~> 0.9.4'
34
+ spec.add_development_dependency 'puma'
35
+ spec.add_development_dependency 'rails', '>= 4.0.0'
36
+ spec.add_development_dependency 'rake'
37
+ spec.add_development_dependency 'rspec', '~> 3.7.0'
38
+ spec.add_development_dependency 'rspec-steps', '~> 2.1.1'
39
+ spec.add_development_dependency 'rubocop', '~> 0.51.0'
40
+ spec.add_development_dependency 'sqlite3'
48
41
  end