Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Tim Nieradzik
    @tindzk
    Hi
    @reactormonk I just pushed it: https://github.com/MetaStack-pl/MetaWeb/ Please let me know what you think
    Simon Hafner
    @reactormonk
    tindzk, give me a day or two for a proper answer, thanks.
    Tim Nieradzik
    @tindzk
    Great, thanks
    Simon Hafner
    @reactormonk
    tindzk, sorry, bad planning, Next weekend at the least for taking a look at MetaWeb.
    Tim Nieradzik
    @tindzk
    No worries. Out of curiosity, why did you decide to use http4s?
    Simon Hafner
    @reactormonk
    Because I don't like guice.
    Also, because their FP ideology aligns with mine, it's easier for me to abstract things. Auth? Just compose Kleisli[Task, Request, Response]
    Simon Hafner
    @reactormonk
    @tindzk, Any reason you skipped scalatags?
    Simon Hafner
    @reactormonk
    Chaning values via := seems obvious, Diff should work nicely too. Gotta see how they work out in practice.
    Tim Nieradzik
    @tindzk
    I see. What do you think about Finch? It looks quite similar to http4s.
    MetaWeb re-implements some features of scalatags.
    You can instantiate views using inline HTML or by directly instantiating tag objects: tag.A().href("http://github.com/").set(tree.Text("GitHub"))
    Does scalatags provide any additional features you're missing?
    Simon Hafner
    @reactormonk
    @tindzk, finch looks pretty similar, except with less FP things mixed in.
    Matthew Pocock
    @drdozer
    hum ... I'm not seeing a <script>widget in bindings.HTML -- where do I look?
    Matthew Pocock
    @drdozer
    I've tried wrapping it in raw but I think the scripts aren't being run
    Marius B. Kotsbak
    @mkotsbak
    What are you trying to do?
    Matthew Pocock
    @drdozer
    hook up the ace editor - it means registering callbacks and things
    I have an ugly hack where I load all the js libraries in the page template and then wire things in ready()
    but it means that the js libs for ace are now leaking into all my pages
    Marius B. Kotsbak
    @mkotsbak
    Load it from webjars and it will be in jsdeps js file
    Load that in main html file
    Marius B. Kotsbak
    @mkotsbak
    New Widok like framework with batteries included: http://udash.io
    Matthew Pocock
    @drdozer
    So say I have a Buffer[Foo] and I have a widok widget factory method Foo => Widget. How do I make a div which manages its children acording to the content of that buffer? Do I just map over it and se that as the content of the div?
    Marius B. Kotsbak
    @mkotsbak
    I think so. Have you looked at the todo example? I think it does something like that.
    Matthew Pocock
    @drdozer
    Cheers, that works just fine. So my next question is:
    I can do div(myBuffer map (foo => Widget)) and the content of the div tracks the widgets I make from the elements of the buffer
    can I do d3-like operations where I capture widget creation and destruction events and hook in an action?
    so for example, whenever the div is going to evict a child that no longer corresponds to an element of myBuffer, trigger a fade effect prior to it being actually removed
    Marius B. Kotsbak
    @mkotsbak
    No, I don't think there is anything like that yet: widok/widok#29
    What you could do is to find the dom elements and attach callbacks to them directly to trigger events.
    Marius B. Kotsbak
    @mkotsbak
    Patches would be nice btw :)
    Matthew Pocock
    @drdozer
    I'm thinking perhaps the low level api would be to transform a steam or deltas with a DSL for composing delayed actions.
    Marius B. Kotsbak
    @mkotsbak
    I don't know the details here. Maybe @tindzk could provide some input if you want to try to implement something.
    Matthew Pocock
    @drdozer
    I would like to have a go at an implementation but I could do with a bit of help.
    Tim Nieradzik
    @tindzk
    @drdozer We could add script to bindings.HTML. We probably hadn't added it in the first place because usually JavaScript dependencies are included in the HTML file.
    Would the jsdeps approach suggested by @mkotsbak work for you?
    I've responded to your other questions on the GitHub issue.
    keenz
    @kindlychung
    How does widok compare to udash? https://github.com/UdashFramework/udash-core
    Tim Nieradzik
    @tindzk
    Udash looks really nice. It's written in a modular way and relies on ScalaTags for rendering.
    Widok's DSL is slightly more succinct. Judging from Udash's TodoMVC example you may still need to use jQuery to manipulate nodes.
    keenz
    @kindlychung
    What would be the advantages/disadvantages for each of them?
    @tindzk
    Marius B. Kotsbak
    @mkotsbak
    Udash more batteries included (rpc etc)? While widok syntax maybe a bit cleaner?
    Tim Nieradzik
    @tindzk
    @kindlychung Widok is more lightweight in its design. For example, it has fewer external dependencies and there are some features in Udash that it is lacking (for example RPC or I18N)
    @kindlychung I would also recommend you to have a look at MetaWeb which is a complete redesign of Widok. The goal is to address some conceptual issues and have a smaller core.
    Matthew Pocock
    @drdozer
    so far I have a single page widok application -- how do I alter my code/build/html to convert to a site with mulptiple, independent widok pages?
    Marius B. Kotsbak
    @mkotsbak
    Matthew Pocock
    @drdozer
    OK, so this is in my fooJS sbt module?