Live data from Hacker News

Mithril.js – A modern client-side Javascript framework

mithril.js.org

61–70 of 83 posts

Re: Mithril.js – A modern client-side Javascript framework

#61
post #59

Earlier quoted context omitted.

If they can’t learn basic JavaScript, they should not be touching the code base with a ten foot pole. Designers can still design, but through mockups and comments passed to people qualified to modify code.

If markup and styling are not in JavaScript, designers do not need to touch JavaScript at all.

This is where the whole fight over what "separation of concerns" in the front-end means scores a clean point for the traditional definition.

Re: Mithril.js – A modern client-side Javascript framework

#62
post #48

I love Mithril. I would encourage every React/Vue developer to try it for a small project. Not to convince them to switch (I use all 3), but because I think using tools designed by smart people with a minimal mindset is valuable. Also I really like the hyperscript approach. It just fits my brain. Last I checked, Mithril hyperscript couldn't handle SVG, which is a non-starter for dataviz work. Anyone know if that's st…

Yeah, hyperscript really doesn't get the attention it deserves. SVG works fine with Mithril now, and has for a while. Here's a quick sample: https://flems.io/#0=N4IgZglgNgpgziAXAbVAOwIYFsZJAOgAsAXLKEAG...

That's great to hear. I'm almost wondering if I'm getting my history mixed up. Maybe it did work when I tried it (~ a year ago) but I just stumbled on old information and gave up.

Or maybe I'm thinking of a different hyperscript implementation.

Re: Mithril.js – A modern client-side Javascript framework

#63
Of course what I am about to say is my opinion

I have nothing but great things to say about mithril. It has a wonderful and well documented API that maintains simplicity but manages to cover the entire project (no hidden APIs or undocumented features) to the credit of the mithril community the focus in simplicity is grained into the project from the bottom up.

I have to say that it’s been nothing short of amazing and is the reason I took JavaScript much more seriously.

The community is awesome and very welcoming. The gitter chat is always active and people are happy to chat and answer questions. I credit them with being able to move quickly with mithril.

At my job my entire team uses it and everyone so far has loved it. It’s been great!

Re: Mithril.js – A modern client-side Javascript framework

#64

Earlier quoted context omitted.

True. If you're creating an app that will be used in production then of course you need to use npm, webpack and other tools. But if you're new to a framework and just want to experiment then being able to create an html file with a couple of script tags and writing code removes many barriers to entry. React, Vue and many others already offer this, I thought it was worth mentioning that Mithril does this too.

I don't know. Creating the HTML file, finding a CDN, and adding script tags take more than: npx create-react-app MyApp There is nothing to install, and you have a complete playground to experiment.

https://flems.io/mithril

That link preloads mithril in a web playground and you're ready to go in a couple of seconds. You can even download and continue development locally should the need arise - without the gorilla and the jungle hiding behind it.

Re: Mithril.js – A modern client-side Javascript framework

#65
post #45

The main problem with steering away from templates is that designers who know HTML are immediately alienated from the code base. Same thing with CSS as objects instead of using real CSS. When working with libs that use HTML templates such as Vue, it's still possible for designers to be integrated in the development process. But with HyperScript, JSX, or Mithril, anyone contributing to the codebase has to know JavaScr…

This is one of the biggest reasons I see people citing for Vue>React. I think it's a very easy argument to defend, but I'm sincerely curious how big of a role this plays. Is it really that common to change the HTML/CSS of an app without also requiring changes to the underlying JavaScript? I have no doubt it happens, but I'm wondering if it happens often enough to justify claiming superiority of one popular web framework over another.

Beyond that, out of HTML, CSS, and JavaScript, by far I find CSS the most difficult to work with and get to behave the way I want. Are there really a lot of designers who are experts at this language but don't know any JS?

I think you might be able to measure some of this. I wonder if you could look at some popular web apps that have separate HTML/CSS/JS files and look at the proportion of commits where only the UI changes, vs commits where you have to change the UI and the JS. The hypothesis being that in general you need to change your JS, and thus require a full developer anyway.

Re: Mithril.js – A modern client-side Javascript framework

#66

Earlier quoted context omitted.

Sure. If you still want to be React-like, that is! But React, Preact are still view libraries right? Mithril is a (reasonably) complete framework. It's sufficiently similar to React that if you know React, you can get productive in Mithril very fast. I guess mithril is for people who want a full framework with no fluff that gets out of the way.

> If you still want to be React-like, that is! Well, you (or the author) are comparing it to React in your title, so of course people assume that you're targeting React devs. Now you're saying that it's something different?

I'm saying Mithril is a simpler alternative to React, not React-like. Preact is react-like (same API as react); Mithril isn't.

Re: Mithril.js – A modern client-side Javascript framework

#67
post #42

I credit mithril and it’s fantastic community of knowledgeable devs with really changing my learning style at the outset of my dev career. Essentially from learning by reading, and becoming overwhelmed (as is often reported in the js world), to learning by doing and using technology. I’m sure this happens to many other people through different routes but I personally experienced it through this community. Seeing peop…

Second this. Mithril.js is absolutely incredible, and my coworkers are often surprised at how quickly I can dive into a React project and fix an issue because I don't carry the baggage of doing things "the react way". Every now and then I use software tools where rather than complaining about how x or y should be different, everything seems to be the best possible version of something I'd have come up with myself, an…

> can dive into a React project and fix an issue because I don't carry the baggage of doing things "the react way".

Would they not want your solution to conform to existing solutions; which (regardless of being idiomatic to React) would be idiomatic to the codebase?

Re: Mithril.js – A modern client-side Javascript framework

#68

Earlier quoted context omitted.

Second this. Mithril.js is absolutely incredible, and my coworkers are often surprised at how quickly I can dive into a React project and fix an issue because I don't carry the baggage of doing things "the react way". Every now and then I use software tools where rather than complaining about how x or y should be different, everything seems to be the best possible version of something I'd have come up with myself, an…

> can dive into a React project and fix an issue because I don't carry the baggage of doing things "the react way". Would they not want your solution to conform to existing solutions; which (regardless of being idiomatic to React) would be idiomatic to the codebase?

I usually find the issue, point it out, then they make sure they implement the fix in a way that is not alien to their codebase.

It's not many hands on one project but everyone taking care of their own projects, so it's a bit different where I'm at right now.

Re: Mithril.js – A modern client-side Javascript framework

#69

Earlier quoted context omitted.

> If you still want to be React-like, that is! Well, you (or the author) are comparing it to React in your title, so of course people assume that you're targeting React devs. Now you're saying that it's something different?

I'm saying Mithril is a simpler alternative to React, not React-like. Preact is react-like (same API as react); Mithril isn't.

jQuery is simpler than React. HTML is simpler than React. What a weak selling point, then.
Post reply on HN