I don't want Ruby to become another TS because I'd use a typed language if I wanted one. The problems I use Ruby for don't need the speed of a statically typed language and it's nice using a dynamic one for.
I don't want Ruby to become another TS because I'd use a typed language if I wanted one. The problems I use Ruby for don't need the speed of a statically typed language and it's nice using a dynamic one for.
2. What made JS uniquely nice?
I wanted to leave these questions entirely open to answer, but I'll add my own opinion on (2) because I feel compelled: nothing, JS is quite possibly the worst language ever designed. Certainly the worst in widespread use.
Implicit type conversions.
Function scoping.
Null and undefined, what is the difference?
Accessing an undefined variable doesn't throw an exception.
Assigning to an undefined variable without var puts it in the global scope.
No integer type.
I could go on and on. The only reason it has become successful is because it has a monopoly in the browser.
- Actually using any of the distinguishing features of prototypical inheritance is nearly always a bad idea, which makes the use of that model in the first place very questionable. One of the cornerstones of the language is pretty much one big foot-gun, to be wholly avoided.
I plumb forgot that assigning a variable without `var` or `let` put it in the global scope because TypeScript yells at you for it.
I don't think I've talked to anyone who has gotten "over the hump" with TS and felt like they were missing something from JS - I may be in a bubble though. It's almost frustratingly beloved in my experience.
My view is that I’d use TS if I have to but I’d pick either plain JS / CLJS or something like purescript if I really wanted types.
People argue for a toolchain that takes a static language, compiles it to a dynamic one, then runs it with an interpreter on the server side.
Humanity ended shortly thereafter.
Although TypeScript can be added incrementally, in practice I've only seen it totally replace JavaScript.
While I do believe more people prefer TypeScript over JavaScript, I think it's because those people never deep dived JavaScript or bothered to learn it enough to see how powerful it really is. There are also people that just prefer typed languages and will shun languages without static types.
This really is a religious war and boils down to one's opinion. I like JavaScript without typing.
What power am I no longer able to leverage using TypeScript when it's appropriate to do so?
I think the general point the above commenter is trying to make is that not all typed languages are equivalent: i.e. if you're avoiding TS/typed ruby/etc. because you don't want something like Haskell/Java, then that's not a well-informed decision as they're (all) radically different approaches to static typing, each with their own unique benefits and drawbacks.
TS is nothing like Java nor Haskell. Nor Rust.
(I can't personally speak to Ruby/Pony yet)
Tooling isn't great, it's missing things like a language server (compiler gives good error messages at least), but it's also quite simple (whole syntax fits into a smallish page) and the documentation is decent.
Playing around with it for doing economic simulations. Actors + good multithreaded performance = pretty much perfect for the domain. Makes sense too, the creator and half the core members came from the financial field.
Ruby is my go-to for scripting, one off programs, and anything web-related (blog, putting together a small crud site). For things where I want performance, I just use a compiled/static language.