Fork me on GitHub
#clojurescript
<
2023-02-15
>
Jan Šuráň15:02:24

I'm trying to make Sente working... but I ran out of ideas... 😄 I can receive ws messages, however I can't send anything to the server. I don't see anything literally wrong with my code, I just think I have forgotten something... I can provide more screenshots in the thread.

Jan Šuráň15:02:45

I previously found out that it might be because of a bad CSRF token... However even if I try to make a constant CSRF token it still doesn't work... I just don't know how to fix it... 😄

p-himik18:02:55

There's no difference between (array ...) and #js [...], is there?

phronmophobic19:02:57

according to https://cljs.github.io/api/cljs.core/array > The tagged literal #js [1 2 3] is equivalent to (array 1 2 3) The only difference I can think of is that I think (array 1 2 3) depends on the lexical scope (ie. array could refer to something besides cljs.core/array )

p-himik20:02:43

Ah, huh, right. Interesting that the macro itself is not documented.

slk50019:02:24

I'm trying to embed youtube video with reagent & clojurescript. But can't fix this error "Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://www.youtube.com') does not match the recipient window's origin ('http://localhost:9500')." It's same as in vue https://github.com/kaorun343/vue-youtube-embed/issues/29 but still I stuck with no solution. Anyone tried this before?

p-himik20:02:44

The linked issue seems to describe what to do (I assume the fix is adding an explicit host to the player constructor). Does it not work?

slk50009:02:56

yes, sure I already tried that. Maybe I should try with https://www.npmjs.com/package/react-youtube