News for hackers. Stuff that matters.
Re:Why we switched from Webpack to Vite by krapp on Wednesday April 28, 2021 @06:46PM (#26975207)
> I dunno, I feel that’s like saying that Lisp and Haskell are part of what’s broken about the machine code ecosystem.

It would be if machine code were another high-level text-based language completely unrelated to either Lisp or Haskell with its own semantics, execution model and type system rather than a more directly machine-readable format of those languages themselves.

Javascript is fundamentally different enough from a bytecode for any arbitrary language that, at least to me the distinction matters. I can accept that it works well enough that most people don't care, even though I suspect most of the use cases for doing so (error checking, type checking) could be better served with linters or editor tools for JS itself.

But the decision to avoid actually writing javascript at all costs has contributed a great deal of complexity in the JS ecosystem, which translates into the bloat in the web that everyone complains about, because all of that javascript is wasting time and cycles simulating other languages.

Re:Why we switched from Webpack to Vite by zachrose on Wednesday April 28, 2021 @07:03PM (#26975351)
> But the decision to avoid actually writing javascript at all costs

Who's JavaScript is it anyway? ES7? ES6? Internet Explorer 11's? How do you isolate things for the sake of unit tests and then bring them together into a performant build?

Re:Why we switched from Webpack to Vite by krapp on Wednesday April 28, 2021 @07:27PM (#26975528)
>Who's JavaScript is it anyway? ES7? ES6? Internet Explorer 11's?

Cross-browser compatible Javascript was a solved problem when JQuery and shimming came along.

>How do you isolate things for the sake of unit tests and then bring them together into a performant build?

Use one of the many unit testing libraries and frameworks that already exist for Javascript.