Live data from Hacker News

RFC: Adopt a modern JavaScript framework for use with MediaWiki

phabricator.wikimedia.org

51–60 of 293 posts

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

#52
post #39

Earlier quoted context omitted.

Yea bugs exist, yet there are still thousands of teams using it to build very complex projects with less bugs because of Typescript safety and features. TS tooling either replaces JS tooling or interacts with it seamlessly. It's not like you're skipping JS altogether and there's no type-checking in JS anyway so where's the interference? Can you give a concrete example where TS is a blocking issue for your development…

If you get less bugs because of type checks and you are a serious JS/web dev with 5+ years experience, then your skills are plainly not good enough. People who spent time with JS and webdev in general got to learn that JS is a minefield of a language, and they work with that in mind. Typing discipline is pretty much the first thing people learn when they try doing JS seriously. How to say. There is no way just adding…

Do you still put your seat belt in your car after 5+ years of driving experience? If yes, would you say that you do that because your driving skills are "plainly not good enough"?

Typescript allow you to spend less energy on minor issues like typos and more energy on design. It also provides you with the ability to reason locally about some code. When you inspect a function in js, you cannot know what are the contracts that it has to deal with. To be sure you have to unravel all the calling and called functions.

Typescript also enables better intellisense.

About your issues:

- I never had tsc dying on my hand in 5 years.

- About the transpilation noise: it can be as noisy as you want. Have you checked the default result for the es6 target? It litteraly look like your source code with only your type signatures stripped. The noise comes from the transpilation to lower versions and bundling and those are independent of typescript.

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

#53
post #29

Earlier quoted context omitted.

Why? Typescript just compiles down to JS, and type definitions are used IDEs so they still help when writing JS. How does removing typescript help you?

> How does removing typescript help you? https://github.com/microsoft/TypeScript/issues Please count the number of open bugs JS tooling is already an enormous jenga tower as it is, with tooling breakages eating a double digit of developer time. Adding typescript on top of that would be the real madness. Typescript will not help us a dime with type checking for most of devs we hire are long past the stage when typing…

>Typescript will not help us a dime with type checking for most of devs we hire are long past the stage when typing errors are a thing for them.

Who are these mythical people?

Do they just magically decipher what interface an argument conforms to? What methods are accessible on a returned result from any random library they're using?

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

#54
post #42

Earlier quoted context omitted.

"We have problems, let’s introduce some code style guidelines, linting, error reporting and most importantly tests!" "Nah, let's just switch to Typescript, it will solve all those problems. At least partially."

It’s not either/or. Nice strawman you put up here.

No I didn’t. The statement was that Typescript solves the listed issues, which is obviously not true. There may be of course discussion whether TS _helps_ to solve such issues but you won’t be able to convince me that TS _solves_ e.g. lack of testing.

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

#55
post #8

Earlier quoted context omitted.

To me the difference is that Svelte is a lot more pure JavaScript than Vue. I haven't had the chance to use it in any larger project, but in my small playgrounds, I've definitely enjoyed it more than Vue.

If you wanna see Svelte in production, I’m using it for my homepage: https://webb.page I’m glad to see Svelte growing in popularity here.

Is it open-source? Otherwise it just looks like any other website, the code would be a lot more useful.

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

#56
post #42

Earlier quoted context omitted.

> ...the better your code style, guidelines, linting, infrastructure, error reporting and tests Doesn't TypeScript kind of solves (at least partially) those issues?

"We have problems, let’s introduce some code style guidelines, linting, error reporting and most importantly tests!" "Nah, let's just switch to Typescript, it will solve all those problems. At least partially."

I mean, look at the number of tests needed to replace a few lines of types. You have to check the behavior of your functions for all kinds of invalid inputs. With typescript you still need tests but less of them. And also you can get rid of a lot of input validation in your production code.

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

#57
post #39

Earlier quoted context omitted.

Yea bugs exist, yet there are still thousands of teams using it to build very complex projects with less bugs because of Typescript safety and features. TS tooling either replaces JS tooling or interacts with it seamlessly. It's not like you're skipping JS altogether and there's no type-checking in JS anyway so where's the interference? Can you give a concrete example where TS is a blocking issue for your development…

If you get less bugs because of type checks and you are a serious JS/web dev with 5+ years experience, then your skills are plainly not good enough. People who spent time with JS and webdev in general got to learn that JS is a minefield of a language, and they work with that in mind. Typing discipline is pretty much the first thing people learn when they try doing JS seriously. How to say. There is no way just adding…

Considering typescript compiles down to JS, and incredibly readable JS at that, the fact that your developers are unable to debug the JS directly may indicate that they are not as amazing at JS as you may believe they are.

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

#58

Earlier quoted context omitted.

If you wanna see Svelte in production, I’m using it for my homepage: https://webb.page I’m glad to see Svelte growing in popularity here.

Viewing the source shows an html page without a closing body nor html tag: it's probably not the best case for showcasing it seems. The layout it all over the place too using FFox, (it's fine on Chrome and Safari) so it also seems to be lacking in some basic cross browser testing, which again, is not good news when show-casing a framework, as a frameworks' prime responsibility is to ensure cross browser/platform unif…

> Viewing the source shows an html page without a closing body nor html tag

It's actually not required to close those tags, the browser will interpret them correctly. (You can see this when inspecting the elements on the page, not just the raw source)

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

#59
post #29

Earlier quoted context omitted.

Why? Typescript just compiles down to JS, and type definitions are used IDEs so they still help when writing JS. How does removing typescript help you?

> How does removing typescript help you? https://github.com/microsoft/TypeScript/issues Please count the number of open bugs JS tooling is already an enormous jenga tower as it is, with tooling breakages eating a double digit of developer time. Adding typescript on top of that would be the real madness. Typescript will not help us a dime with type checking for most of devs we hire are long past the stage when typing…

I would never hire a JS dev with this attitude towards typescript nor work for one.

I’ve done JS with and without types. I’d find a new job before going back to working without them. That’s how dramatic the benefits have been in my code.

Post reply on HN