Live data from Hacker News

WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

github.com

51–57 of 57 posts

Re: WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

#51
post #4

Earlier quoted context omitted.

> using native JavaScript without all the BS that comes with TypeScript do you think javascript was just too easy and people had to invent some bs to make it more interesting for no reason? You don't even know what you're talking about when you make the connection from ts to oop. My experience comming into javascript is that it's a garbage language and the web stack was a joke, everything was hard for the wrong reaso…

How does the complexity of CSS make JS a "garbage language"?

> the web stack was a joke

it's a comment about the thinking behind the design of the web stack including js

Re: WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

#52
post #48

HTAs are tied to MSHTML.dll (the old IE renderer) and WSH/CScript is tied to the old, slow IE javascript engine, right? I would expect this to have very limited compatibility, and even with the transpiling, very limited performance. Or is it possible for this to somehow use Chakra, or Edge's V8 engine?

Yes, the Chakra mode is also built-in. This is because Chakra (not ChakraCore) is an engine embedded in Windows. However, it has not been thoroughly tested.

Re: WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

#53

Earlier quoted context omitted.

> TS has overtaken JS for the majority of web development Has it? Or is that "just like your opinion, man"? Any citation? There's some sources that say it's more popular based on things like social mentions, etc, but that's a vanity metric. Perhaps the statement is true if you mean "web development" to be a very limited scope (like SPA using a build step), but I'm not even sure that's true then.

For new, modern projects, yes. Very much so. There is practically no reason to choose JS over TS, even for high performance projects where every byte counts and you may want stricter control over the transpilation. The ecosystem has grown to the point where other optimizations like tree shaking do far more, and the improvement in the local dev cycle is insurmountable between the two. Obviously this doesn't apply to e…

I'm sorry... high performance JavaScript/Typescript?

Re: WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

#54

Earlier quoted context omitted.

For new, modern projects, yes. Very much so. There is practically no reason to choose JS over TS, even for high performance projects where every byte counts and you may want stricter control over the transpilation. The ecosystem has grown to the point where other optimizations like tree shaking do far more, and the improvement in the local dev cycle is insurmountable between the two. Obviously this doesn't apply to e…

I'm sorry... high performance JavaScript/Typescript?

I don’t think your comment could be interpreted as anything other than snarky and rhetorical.

Nevertheless, it is of course very well known that efficient code in JavaScript will never run as fast as in a language such as C, but choice of language is a trade off, and in whatever language you choose you may also choose to be as “high performance” as possible within it even if it’s still not as performant than if you’d chosen a different language.

Re: WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

#55

Earlier quoted context omitted.

You're wrong. The prototypical model of JS was inspired by the Self programming language[0], itself a descendant of Smalltalk. It is a very crude implementation for sure, but it is object programming nevertheless. Closures being present sours the purity a bit, but closures are poor man's objects[1] anyway. [0]: https://selflanguage.org/ [1]: https://stackoverflow.com/a/11421598

Also, Smalltalk was heavily inspired by LISP[0]. The line between functional and object-oriented is quite blurry. Especially in a pure OO language like Smalltalk. The dynamic and prototypical model of JS is definitely another example of the subtle harmony of functional and OO. [0]: https://worrydream.com/EarlyHistoryOfSmalltalk/

I agree 100%. I firmly hold the belief that the two paradigms are just different perspectives of looking at the same thing (state and behavior). Also see https://insearchofsecrets.com/2014/08/04/lisp-smalltalk-and-...

Re: WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

#56
post #2

Quite amazing solution. From the .hta file you can see it was inspired by VBScript (whose most popular software is ILOVEYOU I guess). It looks like the ultimate hack, but why not ? It's very creative and the intention is good as well: TypeScript/JavaScript is a very popular language. Though C#.NET is great as well. It could make sense in the very long-term that Microsoft themselves explore this possibility. Ultimatel…

What about just straight jscript?

Re: WelsonJS: Build a Windows app on the Windows built-in JavaScript engine

#57
post #33
post #3

Been doing this since 1999. The only thing novel I see here is the transpilers - but you know… you don’t need that. You can build HTAs with native JavaScript, CSS and HTML - and with a little VBScript mixin, directly work with Windows libs. Back in ‘99 and early 00’s I was delivering “thin-client” control panels & management tools for server farms, sensitive accounting data, among a variety of other things. It was (a…

> without all the BS that comes with TypeScript, etc. JavaScript is so powerful and amazing, it’s a bummer to hamstring your app by using TypeScript and classic OO inheritance models Typescript is no more OO than JS is. Typescript is simply a way to document, and optionally compile time enforce, what fields objects have and what objects methods/functions take in and return. That is all TS does. It documents what is a…

> That is the type of bug TS prevents from ever happening.

A linter would do the same, way better and faster.

Post reply on HN