GithubHelp home page GithubHelp logo

Comments (8)

Araq avatar Araq commented on June 11, 2024 1

"Knete" is the working title for "Karax's DSL without the DOM diffing algorithm". The DSL simply produces real DOM nodes. Unfortunately this brings back all of the downsides of heavily state based programming. But it's still something I think is worthwhile to look into.

from karax.

geotre avatar geotre commented on June 11, 2024 1

Normally the dom looks like this:

image

The extension inserts elements alongside the textarea:

image

Causing exception

image

The exception is triggered by one of the doAssert same(...) calls (e.g. 1, 2, 3). I'm not sure which it is exactly because the forum is compiled with an older copy of Karax.

from karax.

geotre avatar geotre commented on June 11, 2024 1

Can reproduce the issue with something like this:

import std/dom
include pkg/karax/prelude

var val: cstring

proc draw: VNode =
  buildHtml(tdiv):
    textarea:
      proc onkeyup (ev: Event, n: VNode) =
        val = n.value
    p: text val

setRenderer draw, clientPostRenderCallback=proc =
  document.getElementById("ROOT").appendChild(document.createElement("p"))

Basically anything that adds elements as a descendant of the Karax root node

from karax.

Araq avatar Araq commented on June 11, 2024

Well you can diactivate the assertions and see if it works out...

from karax.

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.