Open
Description
The example isn't working for me when I'm trying to implement it into a Rails 7.1 project with ESBUILD and Tailwind.
$ esbuild app/javascript/*.* --bundle --sourcemap --outdir=app/assets/builds --public-path=/assets
X [ERROR] Top-level await is currently not supported with the "iife" output format
app/javascript/application.js:84:0:
84 │ await window.LambdaCable.start();
╵ ~~~~~
Edit: I've manage to solve this by using something like this:
(async () => {
await window.LambdaCable.start()
})();
However it's still not working.. The browser tries to make requests to the CloudFront distribution instead of the API Gateway. The action_cable.mount_path
and action_cable.url
are overwritten in the production.rb
. Any ideas?
Metadata
Metadata
Assignees
Labels
No labels