-
Notifications
You must be signed in to change notification settings - Fork 759
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: get started docs r-r version #1325
Conversation
docs/get-started.md
Outdated
@@ -51,7 +51,7 @@ Also update the Babel configuration in the `package.json` file: | |||
|
|||
4. Install `react-rails`: | |||
```bash | |||
$ bundle add 'react-rails' --strict | |||
$ bundle add 'react-rails' --strict --version '3.1.1' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This way, we should update the docs for every single release. Isn't it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm how about like bundle add 'react-rails' --strict --version '>=3.1.1'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is important to install "exact" version for both the Ruby gem and node package. This is emphasized in the documentation as well.
@@ -51,7 +51,7 @@ Also update the Babel configuration in the `package.json` file: | |||
|
|||
4. Install `react-rails`: | |||
```bash | |||
$ bundle add 'react-rails' --strict | |||
$ bundle add 'react-rails' --strict --version '>=3.1.1' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should use "exact" version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But I see one point. --strict
doesn't count the patch version and when we have fixes and bump the patch value in the version, --strict
doesn't help.
If there is any better proposal (than manually fix the version) please share.
CC: @Judahmeek @justin808
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not seeing the value of any changes. What am I missing?
Is there a reason why we're suggesting using |
Because Any suggestion? I can think of making some hooks in our release script to bump the version in the documentation as well. Not ideal. |
ah right it's As I've pushed for over in Shakapacker, I don't think we should be encouraging people to pin to exact versions since it tends to make things more brittle in managing updates (especially for security fixes), and the whole ideal of patch versions is they should not be breaking - I know it's not impossible for there to be a dependency between the Ruby and JS versions of the package for a particular bug fix, but in reality how often has that actually happened? I think the better long-term path is to help the user ensure the versions are in sync like what's being done in Shakapacker - effectively shakacode/shakapacker#156, which probably could be done by just copying over the version detection logic stuff? Noting though I have actually somewhat deliberately ignored this part of tbh it feels like a bug in Bundler that |
I agree. Twice, I thought about it but then left the issue. Perhaps they cannot change the behavior of the |
@ahangarha @G-Rath ready to merge? |
If this changes, then we should also change react_on_rails for the same issue. We have this documentation: https://www.shakacode.com/react-on-rails/docs/getting-started/ |
@justin808 The only solution I can think of is to update the docs in our release script. |
By the way, thanks for the initiative. |
@ahangarha np, thanks for reviewing :) |
Summary
edit
get-started.md
to include latest version of react-rails #1324Other Information
Pull Request checklist
Remove this line after checking all the items here. If the item is not applicable to the PR, both check it out and wrap it by
~
.- [] Add/update test to cover these changes- [ ] Update CHANGELOG file