Re:Xeact 0.0.69: A Revolutionary Femtoframework for High Eff...
by MrDOS on Friday November 19, 2021 @09:15AM
(#29277328)
> I've never understood why this is deemed such a big ask by so many people.
It's the “Script” bit of “JavaScript”. Once your scripting language needs compiling, it's jumped the shark. You need to go back to the drawing board and invent something else. “I don't want to compile JavaScript” is the face of it, yes, but at its core, this sentiment rails against the entire bloated, over-developed, under-engineered state of contemporary JavaScript.
Re:Xeact 0.0.69: A Revolutionary Femtoframework for High Eff...
by godDLL on Friday November 19, 2021 @02:11PM
(#29281017)
Yeah, JS is trying to be too many things to too many uses.
Re:Xeact 0.0.69: A Revolutionary Femtoframework for High Eff...
by gorgoiler on Friday November 19, 2021 @12:07AM
(#29274018)
You present two choices:
1/ no compilation step during development, but it breaks old browsers;
2/ continuous compilation while developing so that you support old browsers;
…but there ought to be a third option that would satisfy everyone:
3/ no compilation while developing, and one compile step at release time to support older browsers.
Re:Xeact 0.0.69: A Revolutionary Femtoframework for High Eff...
by xena on Friday November 19, 2021 @12:13AM
(#29274042)
Ironically this is the kind of thing that ES6 modules actually solves. It's even better if your tool is internal-facing only so that you don't have to bother with the release time older browser compatibility thing.
Re:Xeact 0.0.69: A Revolutionary Femtoframework for High Eff...
by tompazourek on Friday November 19, 2021 @12:53AM
(#29274265)
ES6 modules are just brilliant, it's like a breath of fresh air in JavaScript development. Your browser sees exactly the same thing as you write, which is such a great simplification. And yeah, you can still bundle/minify for production...
I've never understood why this is deemed such a big ask by so many people. You can either compile JS-to-JS or have your JS break when it encounters an old browser (which is exceedingly rare, these days, so you don't really need to compile JS-to-JS. Most of the "bullshit" [aka tooling] these days bundles and optimizes your JS).
Many languages have compilers that you need to run. Before running a Java program, you need to compile it. And compiling things with `javac` is hardly simple. You need to populate your classpath, configure all kinds of stuff. It's not trivial. So why is it such a big deal when you need to do the same thing when making a webapp?
To make meaningful, portable applications in JS, you need to use a compiler. That's both due to the varying runtimes your code will encounter, and due to the fact that your application consists of many files that benefit from being compiled together by tooling versus by you, by hand. Configuring such a compiler (webpack, parcel, rollup, etc) can be of varying levels of complexity. Next.js makes starting a webapp trivial. It's what create-react-app should be.
Yeah, if you want to just make an HTML, that's fine, you can just roll some JS and it'll probably work in most browsers. But if you're making an application, then it makes sense to start using some tooling. When has this not been the case in web development? Even before client-side apps really took off, getting your server-driven HTML-emitting application going was hardly simple.