
Announcing TypeScript 2.9 RC - pingec
https://blogs.msdn.microsoft.com/typescript/2018/05/16/announcing-typescript-2-9-rc/
======
maxxxxx
We are starting up a new web project. I have worked with typed languages my
whole career so I am not really fond of JavaScript. We are mostly C# guys so
Typescript feels very familiar. What do people think of TypeScript? Is it a
good alternative to JavaScript? Our first tests look really good but I wonder
if there are any downfalls.

~~~
Ari_Ugwu
I will give you my very humble opinion:

The front end world is a land of sand castles. If you put in the work and care
to make yours wonderful then I'm sure there is a sense of pride and
accomplishment at what can be done with the tools.

However, the tide will come in and it feels like it comes in daily to threaten
to wash away all of your work. You do not control the tide.

\-----------------

By the above I mean that you will need to fully own the application life cycle
management and realize that for as great as Typescript is virtually _none_ of
the examples you see will be based in it and there will always be some level
of disconnect between what you are doing and what most everyone else is doing.

I think Typescript is a great fit _if_:

a) You ship a part of the project that _only_ has to interface with your TS
code post compilation/transpiling. For example a little proxy shim responsible
for server round trips or the business logic that the front end devs will
call.

b) You are using Angular.

Otherwise use whatever the core framework you adopt is using. Usually just ES6
+ Babel + a nice linter + tests.

Hope that helps. I'm a C# dev and I've tried and failed to use TypeScript for
years. Mainly because the buy in is usually for React/Vue/etc and the JS front
end land is squirrely enough without my having to mentally translate every
example I see into TS. I've come to terms with doing one mental switch during
my day between logical tiers (front end, middleware, backend). I try to limit
the additional context switching I have to do once in those spaces.

Hope that helps.

~~~
maxxxxx
Thanks for the input. Reminds me a little of Xamarin. Sounds really appealing
but in the end you are often better off going native.

~~~
avtar
Could you please expand on your Xamarin vs. native comment? I’m assuming you
aren’t referring to Xamarin.Forms.

~~~
maxxxxx
Our mobile team was working on creating an app a while ago. We are all C#
coders so the obvious solution seemed Xamarin because you can use C# plus you
get multi platform. First they dumped Forms and went with a native UI. Then
there were a ton of bugs (don't know the details) in Xamarin that caused them
to switch to Java on Android. The iOS version will probably be written in
Swift. Noone is talking about Xamarin anymore.

~~~
avtar
> Then there were a ton of bugs (don't know the details) in Xamarin that
> caused them to switch to Java on Android.

Interesting. Those are the type of day-to-day details that I'm curious about
when I see cross platform solutions like Xamarin, Kotlin Native, or React
Native.

------
suzuki
I am afraid they omitted "?" at

    
    
      type Partial<T> = {
          [K in keyof T]: T[K]
      }
    

in their announce. It should be

    
    
      type Partial<T> = {
          [K in keyof T]?: T[K]
      }
    

to make

    
    
      interface Thing {
          foo: string;
          bar: number;
          [baz]: boolean;
      }
    
      type PartialThing = Partial<Thing>;
    

equivalent to

    
    
      interface PartialThing {
          foo?: string;
          bar?: number;
          [baz]?: boolean;
      }

------
pudebe
I think they should stop to pack more and more type-featzres in each release.
I know you do not need them all, but still if you use typescript you should be
aware of all features, which become more overwhelming with each new release. I
think many features should be made optional / unlockable like babel does that
in their .babelrc

