rwr-alt
v0.1.0
Published
This integration makes it possible to populate and share Alt stores between react component located in different part of rails views.
Downloads
1
Maintainers
Readme
rwr-alt
Alt.js integration plugin for react_webpack_rails.
This integration makes it possible to populate and share Alt stores between react component located in different part of rails views.
Setup
- Add
rwr-alt
to your Gemfile:
gem 'rwr-alt'
- Install rwr-alt package:
$ npm install --save rwr-alt
Usage
In chosen view, before components are rendered, add:
<%= alt_store('exampleStoreName', foo: @bar) %>
Then connect to store state in components like you usually do in alt .
Contributing
Issues
Found a bug in rwr-alt? Open an issue on GitHub Issues.
Pull requests
Interested in contributing to rwr-alt? That's great, and thank you for your interest!
After checking out the repo, run bundle exec rake setup:all
to install every environment dependencies.
To get your contributions accepted, make sure:
- All the tests pass. Run
bundle exec rake test:all
. - Any new code paths you've added are covered by tests.
- Describe your changes in pull request (what it adds, how to migrate from previous version etc.)
License
The gem is available as open source under the terms of the MIT License.