Live data from Hacker News

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

github.com

31–40 of 57 posts

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

#31
post #28
post #25

Earlier quoted context omitted.

Certainly we had large teams using JS before TS - back in ye olde days before modules, when everyone picked or built a smallish abstraction (e.g. jquery) and built smallish unconnected things on top of it. But now that modules are mature and thousands of files can all reference each other, types are just necessary. They don't have to be declared in TS - you can get by to various extents with JSDocs or inference - but…

It’s fair that there are proponents & value props beyond those early folks that came from the Java type world. I guess I’m tainted/jaded by the early proponents and initial rationale that was absolutely tied to - “ewwww dynamic types!?! Gross, where are my strong/static types!?”. I’ve just fought that too many times - and that was a very strong argument at the inception of TS. There certainly are value props that go…

I've worked adjacent to TS since it was a thing and I've never heard of anyone associating it with Java or classic OO or the other stuff you've brought up. Maybe it's seen that way by some other community somewhere, but not by TS users.

I mean - it's literally just JS with types! It still has closures, and still has everything about JS one can call functional. It's not some dramatically different language - it's JS, with a large category of runtime errors changed into linter errors. (And that's why people use it - not because they think "eww gross!" about something, which is a frankly silly thing to claim.)

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

#32
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…

> JavaScript is so powerful and amazing, it’s a bummer to hamstring your app by using TypeScript and classic OO inheritance models that preclude the beauty and dynamics of JavaScript as a functional, prototypal language.

The idea that Microsoft was attempting to turn JS into an object oriented C# clone was a very common objection in the early days of TS (especially since one of the lead developers on the project is also the primary architect of C#). That objection ended up being completely false. TS aims to type check the full gamut of existing JS, and embraces all of the language's quirks and idioms. There are people doing serious functional programming in TS with libraries like fp-ts and effect (which is basically the TS version of Scala's Zio). If this is your primary objection I would give TS a second look.

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

#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 already there so you don't make typos on field names.

Lately I'm writing a project w/o typescript and I spent an hour finding a bug the boiled down to "tilewidth" vs "tileWidth". (The code didn't explode until much later when a computed value didn't exist)

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

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

#34
post #10
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…

I think, based on many battles, a lot of folks in the early days that came from Java/C++ absolutely struggled with the key concepts of JavaScript, couldn’t find “features” (like strong typing) they claimed were critical for writing good software and invented ways to make the language fit their paradigm, rather than really deep dive into the language and embrace it. There were constant battles back then - and I’m sure…

> couldn’t find “features” (like strong typing) they claimed were critical for writing good software

How about reasonable scoping rules?

Pre-es6 JavaScript was a nightmare of ugly hacks needed to make the language usable. that = this and {...}() All over the place.

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

#35
post #28
post #25

Earlier quoted context omitted.

Certainly we had large teams using JS before TS - back in ye olde days before modules, when everyone picked or built a smallish abstraction (e.g. jquery) and built smallish unconnected things on top of it. But now that modules are mature and thousands of files can all reference each other, types are just necessary. They don't have to be declared in TS - you can get by to various extents with JSDocs or inference - but…

It’s fair that there are proponents & value props beyond those early folks that came from the Java type world. I guess I’m tainted/jaded by the early proponents and initial rationale that was absolutely tied to - “ewwww dynamic types!?! Gross, where are my strong/static types!?”. I’ve just fought that too many times - and that was a very strong argument at the inception of TS. There certainly are value props that go…

TS rocks so hard for doing pure functional stuff, and its support for type algebra can be an absolute blast.

I try to avoid OO now days, and TS is my go-to language for modeling problems in the functional domain!

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

#36
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…

TS compiles down to JS, so there's no hamstringing involved. Beyond that, you don't have to use Class at all with TS, you can stay functional and the inheritance models are exactly the same as TS runs in a JS engine.

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

#37
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…

> it’s a bummer to hamstring your app by using TypeScript and classic OO inheritance models that preclude the beauty and dynamics of JavaScript as a functional, prototypal language.

I think you have outdated view of TypeScript. Using generics and conditional types you can model the "beauty and dynamics" pretty well, without any OO pattern (if you wish so).

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

#38
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…

The amount of people that think they know better in the comments is insane. TS warriors, give us a break.

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

#39
post #8

Earlier quoted context omitted.

Static/strong typing is not necessary in JS. Yes, ES6 brings the OOPiness

That’s just like your opinion, man. Just because you think that doesn’t mean it’s true. The sheer fact that TS has overtaken JS for the majority of web development says enough.

[flagged]

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

#40
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…

> JavaScript is so powerful and amazing, it’s a bummer to hamstring your app by using TypeScript and classic OO inheritance models that preclude the beauty and dynamics of JavaScript as a functional, prototypal language. The idea that Microsoft was attempting to turn JS into an object oriented C# clone was a very common objection in the early days of TS (especially since one of the lead developers on the project is a…

The problem i see is basicLly, youre doing forced TDD, and thats a inherent cost in quickly developing and deploying apps at the small scale where JS excels.

Ita clearly great for large orgs and interchangeable devs.

Post reply on HN