News for hackers. Stuff that matters.
Re:The Svelte Compiler Handbook by orange8 on Sunday April 05, 2020 @06:44PM (#22789355)
I get it. You like TypeScript, it works for you. You like and firmly believe in static types, also great. No one is asking you to stop using them, or suggesting that they are bad. They are all just tools, use the ones that work for you. Personally, I do not need TypeScript, ESlint gets me there, but then again I'm not you. Just like I'm not going to assume your code is completely perfect and bug free because you use tool X, you should not assume mine is bad and buggy because I use tool Y.
Re:The Svelte Compiler Handbook by jolux on Sunday April 05, 2020 @07:05PM (#22789485)
I’m not assuming it’s bad and buggy code. My day job is writing Elixir, albeit with full type spec coverage, and the code is fine. But that’s enabled by an extensive test suite, as well as type specs. Do we need these things, strictly speaking? No. But we don’t really need any of the tools we build and use, yet we build them because they make certain things easier and more reliable.

My code is not perfect and bug free when I write it in a strongly typed language, however it is guaranteed to be free of type errors provided the type system is sound. That level of confidence in types is just not possible in a dynamic language.

Re:The Svelte Compiler Handbook by orange8 on Sunday April 05, 2020 @07:35PM (#22789649)
> it is guaranteed to be free of type errors provided the type system is sound

Give me an example of a sound type system.

Re:The Svelte Compiler Handbook by jolux on Sunday April 05, 2020 @09:45PM (#22790248)
STLC
Re:The Svelte Compiler Handbook by orange8 on Sunday April 05, 2020 @10:42PM (#22790505)
> STLC

Software Testing Life Cycle? That is not a type system, that is a software development methodology. Thought you'd mention atleast TypeScript or Elixir, but no, you went for the a whole software development methodology. Which kind of puts you in a bind now, since you also said: "..it is guaranteed to be free of type errors provided the type system is sound". So where does that leave us if you cannot confidently give an example of a sound type system?

> That level of confidence in types is just not possible in a dynamic language.

Not possible with static languages either, unless ofcourse you use the whole "Software Testing Life Cycle". Do you know what I like most about STLC? It advocates what I have been saying all along: discipline and best practice!!!

And you can use STLC with dynamic languages to and get the same benefits.

Re:The Svelte Compiler Handbook by jolux on Sunday April 05, 2020 @11:04PM (#22790616)
> Software Testing Life Cycle?

No.

Re:The Svelte Compiler Handbook by orange8 on Monday April 06, 2020 @02:28AM (#22791331)
> STLC

>> Software Testing Life Cycle?

> No

Ok. Since you were saying things like "..that’s enabled by an extensive test suite, as well as type specs" I assumed it must be something to do with testing. Must be a programming language I've never heard about then.