Live data from Hacker News

Deno will stop using TypeScript

startfunction.com

121–130 of 359 posts

Re: Deno will stop using TypeScript

#121

Earlier quoted context omitted.

Lisp is not popular. Remove the browser practical monopoly, and JS popularity would vanish.

I disagree on the current sentiment but agree that browser monopoly pushed js on people. If js didn't evolve over the last few years (since es5), I would have believed removing it from the browser would kill it. Right now, you have options to avoid writing js at all. There might be some glue code in js but you can write vast majority of your code in other languages and target js. People still choose to write in js. P…

tbh JS is popular only because of browser monopoly. JS became popular because of internet usage otherwise it would just die. It started with 1997 changed little at 1998 and 4th edition was even abandoned lol. and it took so long to evolve after that. in 2019 there was update and from 2015 we are seeing good progress. no we still cannot avoid because browser needs it. Hopefully wasm can replace but it still has long way to go.

So i don't subscribe to idea that js is not popular because of browser monopoly.

Re: Deno will stop using TypeScript

#122
This is a great victory for Ecmascript. Typescript is a great hinting support language, I use it with JsDoc to check my (not transpired, vanilla js) code. But it cannot replace JavaScript and is not a JavaScript superset. I think If anyone what to accept the drawbacks of have transpiration of source files can choose better alternative to typescript.

Re: Deno will stop using TypeScript

#123
post #22

Earlier quoted context omitted.

You don't have to write as many tests when you use static typing, because your method contracts are solid. You can refactor your entire codebase with a few operations and don't have to worry about anything breaking. Is your timestamp in seconds? Millis? Is it a duration? Does it have a time zone? Have you ever written a method that returns more than one type of thing? Or had polymorphic inputs? Where are your dynamic…

You don't have to write as many tests when you use static typing, because your method contracts are solid. People often say this, and I don't get it. What JS tests are you writing that become unnecessary in TypeScript? I've used a fair amount of TypeScript and plain JS, and end up with similar amounts of tests for each. With JS, I almost never want to verify only that a value is of a specific type; I want to look at…

Let's say you have a method that takes a thing:

    function doSomething(thing) { ... }
How many different possible representations of a 'thing' do you have? A json object? A class object with behaviors? A database id? Some sort of natural key like a SKU? A URL? Is it a metric or imperial thing?

You need integration-level tests around every method call to ensure that caller and callee agree what kind of 'thing' representation to use. Type systems can eliminate this class of bug entirely.

Re: Deno will stop using TypeScript

#124

Earlier quoted context omitted.

I disagree on the current sentiment but agree that browser monopoly pushed js on people. If js didn't evolve over the last few years (since es5), I would have believed removing it from the browser would kill it. Right now, you have options to avoid writing js at all. There might be some glue code in js but you can write vast majority of your code in other languages and target js. People still choose to write in js. P…

tbh JS is popular only because of browser monopoly. JS became popular because of internet usage otherwise it would just die. It started with 1997 changed little at 1998 and 4th edition was even abandoned lol. and it took so long to evolve after that. in 2019 there was update and from 2015 we are seeing good progress. no we still cannot avoid because browser needs it. Hopefully wasm can replace but it still has long w…

I am not disagreeing with that?

Re: Deno will stop using TypeScript

#125
post #16

Earlier quoted context omitted.

Lisp is large, important, and also not statically typed. It's worked out ok for Lisp programmers. JS itself isn't strongly typed and is the most successful and important language in the world (probably in the history of programming), so that's two game-changers that don't require static typing.

javascripts success is an accident of history and we have paid a heavy price for it

null is considered billion dollar mistake but in JS there is 2 null so the statement is not incorrect :P

Re: Deno will stop using TypeScript

#126
HN gods, an off topic question.

Would Deno become the new Node?

Do you see a vibrant ecosystem building around Deno?

What I am interested to know primarily is, is the architecture / stack / goals and vision that resulted in Deno viable in the long term?

Re: Deno will stop using TypeScript

#127
post #14

Why such a large, important project would want to drop static types is beyond me. > TypeScript isn’t proving itself helpful to organize Deno code. On the contrary, the Deno team is experiencing the opposite effect. One of the issues mentioned is that they ended up with duplicate independent Body classes in two locations This feels like process immaturity or unfamiliarity. Thousands of other projects manage to do just…

This is enough reason for me to completely forget Deno. They clearly cannot write code or organize it without using classes, which is the core of their current error. The fact that they would choose that stupidity over the organizational benefits of interfaces and static types is not something I can reconcile.

remember deno is written by same person who wrote node js so please don't judge immediately.

Re: Deno will stop using TypeScript

#128

This is gonna be an unpopular opinion but as someone who learned to program in loosely typed languages, I have never seen the TS appeal. TS feels like something that was created to lure programmers who couldn’t wrap their heads around JS loose nature. Almost like it was created to convince Java and C# developers to use JS. It have never felt about it like something that would make my code better or more organized. It…

> who couldn’t wrap their heads around JS loose nature

Ultimately, for any serious work, especially enterprise level work, your team members may include people of different calibers.

In such a case, where you have to work with code written by other members of your team, it becomes a serious problem to develop quality code.

For lone developers, it should not be a problem. But in enterprise settings, I think that is the reason why Node is not popular.

Re: Deno will stop using TypeScript

#129
post #43

Earlier quoted context omitted.

For dynamically typed languages, the idea is you make up for that class of bugs by incorporating TDD and having lots and lots of unit tests. So, instead of waiting a minute for the typescript compiler, you wait for the engineer to write tests.

and you wait a minute for the tests to run every time you commit a change

You could arrange to have a program write those tests for you based on your description of the project's data model. Oh wait...

Re: Deno will stop using TypeScript

#130

Earlier quoted context omitted.

Nodejs showed that a lot of developers are lazy and want 1 language to learn

Certainly you didn't go through the entire pro con list of Node over other languages and go "it must be developer laziness!" Easy to reason about, great performance for most cases, simple to debug and write code for, a plethora of libraries, easy to ship, no need to have different teams for backend/frontend, and minimal tooling needed.

The only really unique thing JS is bringing to the table is that it also has a privileged position in the front end. Your list of benefits it provides boils down to stuff multiple large languages all have, and the one thing that means you can learn just JS.

GP comment was presented somewhat snarkily, but I'm not sure they're all that wrong.

Post reply on HN