mithril testing

https://mithril.js.org/simple-application.html

example

this example is not going to work without npm

Adding Elements

How to add a link using mithril with target _blank

m("a[href=https://mithril.js.org/simple-application.html]", {target: "_blank"}, "simple application"),

Nesting elements

m("ul", [
    m("li", "item 1"),
    m("li", "item 2"),
]);

Inline styles

m("div", {style: {border: "1px solid red"}});

Links

in my testing efforts to use mithril while i can see the benefits of it, it just seems to make things too complicated. I cant see that the benefits out way the complexity that this will add to web pages.

why not just add jquery and then do page routing that way. (i know its too old skool) but if it works why wouldnt i use it.

Demo

Other Items in js
Page Views

This page has been viewed 396 times.

Search Code
Search Code by entering your search text above.
Welcome

This is my test area for webdev. I keep a collection of code snippits here, mostly for my reference. Also if i find a good site, i usually add it here.

❤👩‍💻🕹