Code Monkey home page Code Monkey logo

Comments (8)

Kwarrtz avatar Kwarrtz commented on April 28, 2024 8

Now that stdweb has canvas support, is there any progress on adding support to Yew?

from yew.

keeslinp avatar keeslinp commented on April 28, 2024 3

If someone is wanting to implement this, I would suggest adding it as a feature to stdweb and then making a service wrapper here. This library already depends on stdweb so it might make sense to add it there.

from yew.

totorigolo avatar totorigolo commented on April 28, 2024 3

I don't have time to elaborate or look at this issue in details right now, but I used a canvas with yew recently: https://github.com/totorigolo/pathbot/blob/87df913bbee5906cb2ccc9e0387f9f14630a5386/src/lib.rs#L599

Hope this helps :)

from yew.

wldcordeiro avatar wldcordeiro commented on April 28, 2024 2

@empath I think you'd likely want to add a service of some sort to get the bridge for canvas support.

from yew.

LifeIsStrange avatar LifeIsStrange commented on April 28, 2024 1

Why a canvas tag in yew does not compile ?
From my naive understanding, yew should support all html tags out of the box without doing any special work ?

Secondly, for using the canvas api, does yew let me use stdweb out of the box ? which would allow to use the canvas api.
If so, the issue should be trivial to fix.

from yew.

keeslinp avatar keeslinp commented on April 28, 2024

Looks like someone already went ahead and added it to stdweb. koute/stdweb#80. It shouldn't be too hard to add here now.

from yew.

Boscop avatar Boscop commented on April 28, 2024

@keeslinp I want to use the canvas fill_rect function from stdweb on a canvas element in a yew app, how can I do that? :)
I'm interested in contributing to expand the canvas API coverage in stdweb/yew.

from yew.

jstarry avatar jstarry commented on April 28, 2024

I think this is no longer an issue, if not, please re-open!

from yew.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.