react_rails_webpack 2.0.4 → 2.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a2e0e208bffed31ac0fea62fccf7ff0f3b6fba56
4
- data.tar.gz: 53ae37a29df2cda276e2e0ccd8e75238657c2e79
3
+ metadata.gz: 915067ad66a0fe783dc0a76cda3caff6992c5e01
4
+ data.tar.gz: 42176dda732bafceac3bed3d7a9e4059b8bde129
5
5
  SHA512:
6
- metadata.gz: d662fff84b84af5030fd960e0e9e93e460b81af1155dcfcdb9250395b2138757aad7b6d28dd7ea691eb238e5c79ebd7ea5fcbc7d370dbe9101d1745bbbffeb35
7
- data.tar.gz: 73ce7f41b6ab4f01b50d886a537d3332f76bcd0aeb8bae1b420483abd114a58b68516683ee36ccfb247c36d330298749dbfc7bc1fd4d3443364e9308a71797cf
6
+ metadata.gz: b1d7b418e5bc5be18f772c634bc7ced3e1903235351b00094484be6e2dc9ca07647d93ab3210bd040d3340f84954d3fa9dbec3643cd7e77d36f8668001e0cde3
7
+ data.tar.gz: 93f0811195cde9c5c85262687fea5c70c228d7bbf6435dd4716c01e6481164219ee44ea5c9a33682bb5d65633a8db6f12441893c8072c1acd0744f6b07ed5519
data/README.md CHANGED
@@ -7,7 +7,7 @@ A set of Rails generators that create all the necessary boilerplate code (with e
7
7
  1. One-command setup
8
8
  2. Use any packages from the npm ecosystem
9
9
  3. Automatically sets up working demo examples so you can jump into React immediately
10
- 4. Development server for React components will live update your changes to any device on your local network (including phones)
10
+ 4. The webpack development server for React components will live update your changes to any device on your local network (including phones)
11
11
 
12
12
  ## Install
13
13
 
@@ -18,9 +18,9 @@ A set of Rails generators that create all the necessary boilerplate code (with e
18
18
 
19
19
  ## Requirements
20
20
 
21
- - Rails version 4 or greater
22
- - node version 4 or greater
23
- - npm version 3 or greater
21
+ - [Rails](http://rubyonrails.org/) version 4 or greater (check version with `rails -v`)
22
+ - [node](https://nodejs.org) version 4 or greater (check version with `node -v`)
23
+ - [npm](https://www.npmjs.com/) version 3 or greater (check version with `npm -v`)
24
24
 
25
25
  ## See the demo components in action
26
26
 
@@ -198,6 +198,12 @@ Components will not be accessible from Rails if you forget to add them here.
198
198
 
199
199
  `rails g react_rails_webpack:new_fork` sets up [the environment.json file](lib/react_rails_webpack/client/environment.json), which is NOT included in your repo, because it contains information specific to each computer it is generated on.
200
200
 
201
+ ### npm install vs. npm run install
202
+
203
+ Usually to install new npm packages, you run the `npm install` command. This will work fine if you do it from the client folder, but it won't work from your project's root, since your package.json file with your project's requirements is in the client folder and not the project's root. However, as a convenience, the project's root has the command `npm run install` which is essentially the same as hopping in and out of the client folder to run `npm install` (it's basically like running `cd client && npm install && cd ..`).
204
+
205
+ More succinctly: if you're in your project's root folder, use `npm run install` instead of `npm install` to install any new npm package dependencies you've added to the `client/package.json` file.
206
+
201
207
 
202
208
  ## Development
203
209
 
@@ -1,3 +1,3 @@
1
- <aside>Find the source for this page in app/views/react_example/greeting.html.erb</aside>
1
+ <aside class="source">Find the source for this page in app/views/react_example/greeting.html.erb</aside>
2
2
  <%= react_component :Hello, @props_for_hello_component %>
3
3
  <%= react_component :HelloWithRedux, @props_for_hello_with_redux_component %>
@@ -5,4 +5,10 @@
5
5
  padding: 20px 40px
6
6
 
7
7
  h2
8
- margin-top: 0
8
+ margin-top: 0
9
+
10
+ aside.source
11
+ text-align: center
12
+ color: darkblue
13
+ font-size: 20px
14
+ margin: 20px 0 35px;
@@ -13,7 +13,7 @@ var config = getConfig({
13
13
  {
14
14
  // title: 'Site Title'
15
15
  // head: '<script src="http://code.jquery.com/jquery-2.1.4.min.js"></script>',
16
- html: "<aside>Find the source for this page in client/webpack.config.js</aside>" +
16
+ html: "<aside class='source'>Find the source for this page in client/webpack.config.js</aside>" +
17
17
  "<div class=\"react-component-target\" data-componentname=\"Hello\" data-componentprops='{ \"details\": \"My initial greeting was set with getInitialState in the client/src/components/Hello.jsx file.\" }'></div>" +
18
18
  "<div class=\"react-component-target\" data-componentname=\"HelloWithRedux\" data-componentprops='{ \"details\": \"My initial greeting was set with initialState in the client/src/redux/reducer.js file.\" }'></div>"
19
19
  }
@@ -1,3 +1,3 @@
1
1
  module ReactRailsWebpack
2
- VERSION = "2.0.4"
2
+ VERSION = "2.0.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: react_rails_webpack
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.4
4
+ version: 2.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Neurodynamic