Live data from Hacker News

RFC: Adopt a modern JavaScript framework for use with MediaWiki

phabricator.wikimedia.org

131–140 of 293 posts

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#131
post #96
post #23

Earlier quoted context omitted.

A reverse situation here. I deal with strict no typescript policy, so besides a problem of finding typescript devs, we have a problem of having to "de-typescript" a lot of 3rd party code. Typescript has a lot of adoption within with ex-Java devs, and with that comes a lot of "Java-think." It's hard for these people to adapt to not doing things "the Java way" and vice versa. And another part of the problem is that peo…

I agree with this. TypeScript makes Java and .NET developers think they understand the language and platform and causes a lot of irrelevant design to be copied over into the JS world where it mutates and becomes absolutely poisonous. Just look at Angular where the boilerplate and crazy dependency injection completely surpasses anything seen in the Java / .NET world.

It's especially apparent when Java / C# developers are introduced to a simple idea like a Flux pattern store.

Store structures, despite the initial difficulty in learning the pattern, simplify things enormously, but can somehow become nightmarishly complicated in the hands of a developer who expresses API/client relationships in terms of Factories and Services... When it's not hell to work with, it's actually quite interesting to observe.

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#132

Earlier quoted context omitted.

These directives take less than a day to learn. 99% of the time it's far easier to write HTML tags with data and event binding directives than hack around with JSX and passing all those props. You can also use JSX with Vue if you want. Just add a render() function to the component. That's what happens anyway when you use a normal template, the Vue compiler turns it into a render function the same way JSX is compiled…

Using Vue's pseudo-HTML directives might be easier for many cases, but it is less powerful than JavaScript. In some cases, these restrictions leads to workarounds or rewrites. I agree with the grand-poster that the added value is controversial. As for JSX with Vue, it's clearly a second class citizen. For instance, last I checked, JSX + TypeScript was broken, though both are officially documented with Vue.

I actually found make it restricted (compare to js) improve general code quality as you don't have too much items to abuse. Probably not ideal for personal project because it won't let you fly as you want. But it is awesome for collaboration because you can't really write something way too off with it.

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#133
I'm not a frontend dev, in fact I know little about the current "cool" JS framework.

That being said, I donate to Wikipedia/Wikimedia every year and I will reconsider if this goes through. This is exactly the kind of bloat that no one needs.

The Wikimedia sites should be seen as a public library where accessibility is the most important thing. Creating a web app with apparently no measurably good impact is pure idiocy.

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#134

Earlier quoted context omitted.

It is standard HTML in the sense that it's valid HTML, which React JSX isn't, of course. But without the JS runtime it won't do anything, so in the end what's the advantage over React? You can add interactivity without going full SPA with React too after all

It's a subtle but huge difference. In React, using JSX means you can create components and mount them on top of the existing elements on the page. With Vue's HTML templates, the page itself can be the component and everything can become interactive. For example, you can easily output a HTML table from server-side code, then Vue can convert that into a interactive component while using the existing structure and data.…

Fantastic point.

Vue has a bit more flexibility in that regard.

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#135
post #111

This is a bad idea. If you look at the list of advantages to doing this only 1 is user-centric (things would be reactive). The rest are all related to how it makes development easier. When you choose a developer-centric workflow your users will suffer. You only have to look at the numerous server to SPA conversions to see how consistently bad of a choice this tends to be; Reddit is a big and obvious example. They cou…

It's not just a bad idea... it's a horrible, dangerous idea. All of their points can be easily addressed with a static site generator or just some CMS that lets you write pages using templates instead of just pure HTML. That's absolutely declarative, a lot more than a JS-framework based app. The only point that would be missing is the reactive part as you mention: but who the hell expects a wiki to be reactive?! I ex…

> a static site generator

You really think 140,000 people are going to learn git all of a sudden?

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#138
post #93

Earlier quoted context omitted.

I'm a React fanboy, but I have to admit, the Svelte performance and code size is impressive. Maybe that would be a feasible way to get a modern developer experience without the bloat?

One of their criteria is widespread adoption. Svelte isn't there yet. One day it probably will be, but today is not that day.

I think that's a chicken egg thing. If Wikimedia adopted it, adoption rates would skyrocket.

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#139

What does this mean for Wikimedia? Will they extend file uploaders and such with some fancier animations and code or will Wikimedia turn into another one of these God-awful Javascript applications running an HTML renderer inside the browser's HTML renderer? Don't get me wrong, Javascript web applications have their place, but Wikimedia is a website and not a web application. Will Vue and React work on 2G cell phones…

>Will Vue and React work on 2G cell phones running super basic browsers?

Yes

>Will screen readers support all elements created by the Javascript framework?

Yes

Re: RFC: Adopt a modern JavaScript framework for use with MediaWiki

#140
post #133

I'm not a frontend dev, in fact I know little about the current "cool" JS framework. That being said, I donate to Wikipedia/Wikimedia every year and I will reconsider if this goes through. This is exactly the kind of bloat that no one needs. The Wikimedia sites should be seen as a public library where accessibility is the most important thing. Creating a web app with apparently no measurably good impact is pure idioc…

Page Previews is a great example of leveraging "web app" that solves many problems at once:

- quickly inform on a topic without clicking through (lower latency)

- increase scanability (hence readability)

- decrease expensive whole page loads

- eliminate need to open many tabs

https://www.mediawiki.org/wiki/Page_Previews

Post reply on HN