fr_cable 0.1.0 → 0.1.1

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
  SHA256:
3
- metadata.gz: 88150a7af3e30e47996ffc531ca66dec61174215bde44c561062b8d08b25afdd
4
- data.tar.gz: 9c202fe7cd9923b6ac8f459383b841278b0f9391563b5df5d298018210cd2d1f
3
+ metadata.gz: 00f4c7dba9ba7b2641c44d5c05a6b379382d080d768e1e593f4f81402c4493a8
4
+ data.tar.gz: 68821217f40a3e5dc45b4d0b22acbd3aa65d5fc36672b8bd32e534eb8bcdff27
5
5
  SHA512:
6
- metadata.gz: e99946ac1358350947b6f92d2ed60482faa84e669440a545b82ae05bf8c9807d738f06a0baac93f1fd150d11049c25d8d5ac9cbeec7b5a2b38110321384f00c0
7
- data.tar.gz: 286e1d372197d8ca047af49cd84a7f3c087824704dc94192697310ca2f98ea24d608d76240169466a4d4282551729c933191060afcbbbec0cb7d6c65caff659c
6
+ metadata.gz: 586333aba3a48c4cadd729f51e250c329cf4901c03557372d4d37f85997815bb5fc18c81a04d8aaf6388e5818627c32e6908b1231f1512f849821970c14547b5
7
+ data.tar.gz: 7e8d2a470b0b1b35b3df7447d830676f954a4c8885b3ff82be23f69fa3ca007229cfcde2cbc02685fa8275bb2243717a3acda79bd0960e9fa555f5004a1dec26
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- fr_cable (0.1.0)
4
+ fr_cable (0.1.1)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/README.md CHANGED
@@ -1,8 +1,8 @@
1
- # FrCable
1
+ # FrCable ruby
2
2
 
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/fr_cable`. To experiment with that code, run `bin/console` for an interactive prompt.
3
+ It's http rake based middleware server impementation for fr-cable-server.
4
4
 
5
- TODO: Delete this and the text above, and describe your gem
5
+ `!!!WARNING!!!` The project is at a very early stage of development, it can be used, but there is no guarantee that it works as you expect and that I will not abandon it tomorrow
6
6
 
7
7
  ## Installation
8
8
 
@@ -20,25 +20,48 @@ Or install it yourself as:
20
20
 
21
21
  $ gem install fr_cable
22
22
 
23
- ## Usage
23
+ Add this line into you `config/application.rb`
24
24
 
25
- TODO: Write usage instructions here
25
+ ```
26
+ config.middleware.use FrCable::Rack
27
+ ```
26
28
 
27
- ## Development
29
+ Then touch `app/channels/application_cable/channel.rb, that contain`
30
+ ```
31
+ class ApplicationCable::Channel < FrCable::Channel::Base
28
32
 
29
- After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
33
+ end
34
+ ```
30
35
 
31
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
36
+ and `app/channels/application_cable/connection.rb`
32
37
 
33
- ## Contributing
38
+ ```
39
+ class ApplicationCable::Connection < FrCable::Connection::Base
34
40
 
35
- Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/fr_cable. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/[USERNAME]/fr_cable/blob/master/CODE_OF_CONDUCT.md).
41
+ end
42
+ ```
36
43
 
37
44
 
38
- ## License
45
+ ## Usage
39
46
 
40
- The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
47
+ You can define channels like in action_cable gem.
41
48
 
42
- ## Code of Conduct
49
+ `app/channels/comment_channel.rb`
50
+
51
+ ```
52
+ class OrderChannel < ApplicationCable::Channel
53
+ def receive message
54
+ broadcast(params[:room], message)
55
+ end
56
+ end
57
+ ```
58
+
59
+ Run fr-cable-server dockerfile near of you app and you already can messaging through fr-cable-js-client npm package.
60
+
61
+ ## Contributing
62
+
63
+ No needed to contribute now
64
+
65
+ ## License
43
66
 
44
- Everyone interacting in the FrCable project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/fr_cable/blob/master/CODE_OF_CONDUCT.md).
67
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
@@ -1,3 +1,3 @@
1
1
  module FrCable
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fr_cable
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitriy