Comments (4)
@dark-panda can you tell us what the error was?
from stimulus_reflex.
@hopsoft I feel like this needs to be flagged as high priority
from stimulus_reflex.
Error connecting controller
TypeError: Error connecting controller - TypeError: this.getConfig is not a function
at createConsumer (action_cable.js:24)
at T (consumer.js:27)
at stimulus_reflex.js:49
at Object.ie [as register] (stimulus_reflex.js:149)
at t.value (info_controller.js:8)
at e.connect (context.js:18)
at e.connectContextForScope (module.js:34)
at e.scopeConnected (router.js:80)
at e.elementMatchedValue (scope_observer.js:42)
at e.tokenMatched (value_list_observer.js:44)
Which in its pre-compiled form looks something akin to this:
Or compiled:
createConsumer: function(url) {
var ref;
if (url == null) {
url = (ref = this.getConfig("url")) != null ? ref : this.INTERNAL.default_mount_path;
}
It appears that it's using its dependency version of ActionCable 5.2.4, but since I upgraded to Rails 6 I'm using ActionCable 6.0.2.2 via the @rails/actioncable
package. I could potentially downgrade or remove that package and just use the 5.2.4 version, but I'm not sure how that would play with the server version. Presumably what's going on here is that I've initialized with the 6.0 version of ActionCable while Stimulus Reflex is using its own version, and the two aren't playing nice. You should only be using one version of ActionCable at any given time.
from stimulus_reflex.
Resolved by #135
from stimulus_reflex.
Related Issues (20)
- Controller over reflex attribute is ignore and reflex is always called with default StimulusReflexController HOT 7
- Broken Next Page Link on Welcome Page of Docs HOT 2
- HEAD and most of the latest releases are broken, references an undefined exception
- StimulusReflex is not compatible with the standalone ActionCable server HOT 9
- Wrong dataset getting from Docs example HOT 2
- NameError: undefined local variable or method `package_json' HOT 3
- Reflex not triggered when a Stimulus controller is also attached to a field HOT 4
- Form parse errors are not captured and reported back to front-end
- Drop Rails 5 and 6.0 support
- `solid_cache` seems to work as well as Rails cache store HOT 1
- Add full-stack tests
- Stimulus_reflex and esbuild error HOT 1
- OpenStruct no longer supported by json HOT 1
- Refactor away instances of OpenStruct
- NameError: uninitialized constant StimulusReflex::Installer::Thor when running rake tasks HOT 1
- Support `relative_url_root`
- Could not find generator 'stimulus_reflex:initializer'
- Unrecognized command "esbuild" (Rails::Command::UnrecognizedCommandError)
- Installer should work in CI (noninteractive) environment
- docs recommend hiredis gem along with incompatible redis version
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from stimulus_reflex.