-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'm having a strange problem with the canvas rendering properly everywhere #4
Comments
Hi Jesse 👋
Because of Elm’s choices regarding interoperability, this library makes use
of a web component to be able to access and interact with the canvas.
When compiling to HTML or serving through reactor the HTML is generated
through the elm compiler, and you don’t have a chance to include the web
component script. With those two methods it happens the same with ports or
any other thing that requires a custom HTML file.
That is the situation right now. 😔
…On Sun, 2 Dec 2018 at 04:11, Jesse Thompson ***@***.***> wrote:
Namely: If I serve the canvas through reactor or through a compiled Html
file, it's always just a transparent rectangle no matter what I put into
it. I've tested this on up to date Opera, Chrome, and Firefox on Windows 10.
OTOH when I try the same thing (exact same code) with Ellie it seems to
work fine in those same browsers: https://ellie-app.com/38zhvnLGCKMa1 :o
Do you reproduce the same, and/or is this a known issue at present? Or is
what I describe difficult for others to reproduce?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#4>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAoJr7LA_Jq7ieQGk68EoPi0Nqlq3n3bks5u00TrgaJpZM4Y9NqA>
.
|
Yay, that seems to work great. 1: Thank you! 2: thanks for being so polite despite my completely borking that being described right in the front page of the docs. 😅 3: I wonder how Ellie makes it work then? Did you make a deal with the Ellie folks to get your component script into the output or something? :B 4: Since you mention "Elm’s choices regarding interoperability", does using this strategy with the web component lead to Elm functions having side effects? EG: do the canvas commands in your module communicate with the outside world (including the canvas) only through a watershed of return values that terminate at TEA (and maybe web component takes over during TEA's watch which would be ideal), and do we maintain the guarantee that every call to a function in your module with input set X always produces an identical output set Y? |
Ellie has a pane for the HTML of the page, in which I set up the web component script in the example from the docs.
This library behaves exactly like the HTML one, so when running the functions there is no implicit side effects, until the HTML gets handled by the Elm runtime 👍 |
Namely: If I serve the canvas through reactor or through a compiled Html file, it's always just a transparent rectangle no matter what I put into it. I've tested this on up to date Opera, Chrome, and Firefox on Windows 10.
OTOH when I try the same thing (exact same code) with Ellie it seems to work fine in those same browsers: https://ellie-app.com/38zhvnLGCKMa1 :o
Do you reproduce the same, and/or is this a known issue at present? Or is what I describe difficult for others to reproduce?
The text was updated successfully, but these errors were encountered: