1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actioncable
Richard Macklin 39493185d3 Remove explicit document receiver from add/removeEventListener calls
This allows ActionCable to be used in a web worker, where the `document`
global is undefined. Previously, attempting to use ActionCable inside a
web worker would result in this exception after you try to open a
connection:
```
ReferenceError: document is not defined
```

The visibilitychange event won't ever get triggered in a worker, so
adding the listener is effectively a no-op there. But the listener is
mainly a convenience, rather than a critical piece of the javascript
interface, so using ActionCable in a worker will still work. (And you
could listen for visibilitychange yourself in a window script, then tell
the worker to reconnect if you still want that behavior.)
2019-01-15 22:14:33 -08:00
..
app Remove explicit document receiver from add/removeEventListener calls 2019-01-15 22:14:33 -08:00
bin Use frozen string literal in actioncable/ 2017-07-23 23:30:29 +03:00
lib Add Action Cable Testing guides 2019-01-14 11:16:59 -05:00
test Replace window references in ActionCable with self 2019-01-14 17:44:35 -08:00
.babelrc Convert ActionCable javascript to ES2015 modules with modern build environment 2018-11-02 08:41:05 -07:00
.eslintrc Convert ActionCable javascript to ES2015 modules with modern build environment 2018-11-02 08:41:05 -07:00
.gitignore Remove circular dependency warnings in ActionCable javascript and publish source modules with fine-grained exports (#34370) 2018-12-01 16:25:02 -05:00
actioncable.gemspec Revert "Revert "Merge pull request #34387 from yhirano55/rails_info_properties_json"" 2019-01-08 22:19:22 +01:00
CHANGELOG.md Add Action Cable Testing guides 2019-01-14 11:16:59 -05:00
karma.conf.js Convert ActionCable tests from CoffeeScript to ES2015 and replace Blade with Karma and Rollup (#34440) 2018-11-26 17:16:02 -05:00
MIT-LICENSE Bump license years for 2019 2018-12-31 10:24:38 +07:00
package.json Move all npm packages to @rails scope 2019-01-10 11:01:57 -05:00
Rakefile Convert ActionCable tests from CoffeeScript to ES2015 and replace Blade with Karma and Rollup (#34440) 2018-11-26 17:16:02 -05:00
README.md Merge actioncable/README.md to the Action Cable Overview guide [ci skip] 2019-01-13 19:45:04 +00:00
rollup.config.js Remove circular dependency warnings in ActionCable javascript and publish source modules with fine-grained exports (#34370) 2018-12-01 16:25:02 -05:00
rollup.config.test.js Convert ActionCable tests from CoffeeScript to ES2015 and replace Blade with Karma and Rollup (#34440) 2018-11-26 17:16:02 -05:00

Action Cable Integrated WebSockets for Rails

Action Cable seamlessly integrates WebSockets with the rest of your Rails application. It allows for real-time features to be written in Ruby in the same style and form as the rest of your Rails application, while still being performant and scalable. It's a full-stack offering that provides both a client-side JavaScript framework and a server-side Ruby framework. You have access to your full domain model written with Active Record or your ORM of choice.

You can read more about Action Cable in the Action Cable Overview guide.

Support

API documentation is at:

Bug reports for the Ruby on Rails project can be filed here:

Feature requests should be discussed on the rails-core mailing list here: