TypeScript vs JavaScript | Guido van Rossum and Lex Fridman

preview_player
Показать описание
Please support this podcast by checking out our sponsors:

GUEST BIO:
Guido van Rossum is the creator of Python programming language.

PODCAST INFO:

SOCIAL:
Рекомендации по теме
Комментарии
Автор

Guest bio: Guido van Rossum is the creator of Python programming language.

LexClips
Автор

Recently, I switched to typescript and I totally agree with what is said at 2:58. At the beginning you find hard to write TS but at the end you find out that TS is way more regular code than ultra permissive JS = which means ultra errors JS.

codewithguillaume
Автор

What I hate about TypeScript is that Microsoft got something right.

SameAsAnyOtherStranger
Автор

I always say that it's easy to write javascript that works, but it;s also easy to write typescript that keeps on working (or at least tells you when it's not working anymore). I'm working in python for the past 6 months where the codebase was written by technicals who weren't programmers and it really shows. Stuff breaks almost every day and the code is super unriable when a change is implemented.

rachellejanssen
Автор

You should invite Brendan Eich sometime, the father of JavaScript. It would be interesting to hear his comments on the state and future of JS

adybose
Автор

I’ve been writing Typescript and JavaScript for 10 years. Having types is so incredibly consistently helpful in every aspect of development that I would recommend Typescript over JavaScript in any scenario.

asherrfacee
Автор

To add to his list of things that Typescript helps with: It makes it easier to work on projects with multiple developers.

driverjb
Автор

when I'm writing for just myself, I usually start with just JS. I learned to write safe JS and think of gotcha's and edge-cases years ago and I love writing unit tests on top of it all. But when I work in a team, I absolutely endorse the use of typescript and making it as strict as possible. This exposes so many shannigans I've seen from cowboy devs and I can use use it to expose their bluffs and short-sighted code. On top of that it increases readability and expresses intent much more clearly. But the final nail in the coffin is graphql + codegen which provides a typed contract for API's. This alone is enough to justify Typescript's use.

BenjiDalton
Автор

Typescript is a revelation for new programmers. Makes it easier to explain wtf type consistency is and that is a huge plus for the future of programming.

bosteador
Автор

Been a web dev for 20 years, used everything there is on the Front end, native web, abstractions, libs. All the same problems that you have in JS, can show up in one way or another, in TS, or any massive client side project, or any massive full stack project. IMHO, pick a language, doesn't matter if its TS, or JS (btw WASM is a thing now in the browser which is what Figma was compiled to). Anyways pick a language use the powerful features of that language to express your logic. But the biggest problem I see isn't, whether it was written in JS or TS, its two fold. You write code to bring value to something, whether it be an app, a business, a job, an education, etc. When you deal with writing code for money, you're at the mercy of the stakeholders, which usually results in an MVP mentality. There are more companies that do app and web dev wrong, than those orgs who holistically from top to bottom do it right. Also a lot of web dev courses and self taught paths have too much paint by numbers tutorial style learning. So someone mentioned training wheels, the wheels are NOT from TS, they are from learning how to accomplish certain predefined purposeful and contextual programming tasks by following a sequence of predetermined steps, vs knowing system design, and proper software design principles. That's why Pragmatic Programmer and Clean Code are still #1 dev books en mass. So learn how to architect software with a pencil first, before you learn a programming language. Also learn how JS engines work. Because the language is so quirky, you can either memorize all the gotchas and take someone else's word for it, or learn why heap sizes and hoisting can fuck you up. For example, you can make your Redux state too big easily, and crash Redux dev tools, just as an easy example of a trap you can easily fall into. I got 1000's. Thanks for the prime time discussion Lex.

sinelanguageMusicProducer
Автор

I started out with BASIC and C++ before I ever touched JS (which is now my whole job). I've always thought dynamic types in JS were a neat feature. From that perspective, TS seems primitive, heavy-handed and deeply inelegant—like going halfway back to line numbers and GOTOs. I like that TS sometimes lets me virtually eliminate runtime type checking, but if the application ends up frequently needing explicit runtime type conversions that benefit sort of washes out. Having Intellisense work better with TS doesn't seem magical to me since I'm well aware of TS front-loading that effort. Refactoring in TS always seems to require changing more things in more places. People seem to derive some sort of left-brained, process-oriented, ducks-in-a-row satisfaction from TS but I absolutely cannot relate.

stevenharder
Автор

The last point about writing JavaScript code for all kinds of screen sizes hits it right in the nail. Save yourself and Always start mobile first.

bytesizedfeed
Автор

Man, Lex Fridman talks about a lot of stuff on his podcast, I'm very impressed

alibarznji
Автор

People treat typescript here as a language although it should be treated as a linter and nothing else. jS docs provide same functionality as Typescript with js language which helps to avoid extra compile step and also run your raw code in any js environment

darkDay
Автор

The biggest help for me using typescript is that it kinda forces you to pay attention to what you're doing instead of just throwing functions around with no regard for what is coming in or what is going out.

jamesvelopmenthagood
Автор

Cannot explain how much easier it is read other's code with typing plus a linter vs using JS. Plus when using TS you have the knowledge base from JS (i.e. SO questions).

soccermaster
Автор

From my experience TS fixes the many baked in issues of JS and makes it more of a first class language. I think it’ll be a super move to make it the standard as it already follows the ES standards pretty closely anyways. You dont have to specify types if you want to write pure JS and still can still gain some inferred checking. For peeps that dont want to use semi colons etc they can just make the linting more lapse to suite so it doesnt have to be TS vs JS.

I’ve been working with TS for so long that when moving to projects written in pure JS, its laughable to see how many stupid type bugs exist that fall into production especially with what JS does with Math rounding etc, not to mention how brittle everything is during refactors or when the API’s change. Why would anyone want that headache all the time just to get shorter pretty code best suited to hobby projects or tut videos.

Ultriix
Автор

Once you go TS you never go back. "Just trust me bro"
Only time when I use JS is when I need to test some JS code quickly in browser console...

alexeysmolyaninov
Автор

Typescript means no more running your app just to see a console.log; better to read other peoples codes, meaning you can really take advantage of your IDE / Editor and see what interface / type your value belong to. Typescript actually made me have fun converting old JS little projects to TS and It was so easy to start scaling them later.

murilomelo
Автор

Typescript vs JavaScript questions are the only time that you do not hear a senior developer give you a reply of "It depends"

TheedonCritic
visit shbcf.ru