Why are some big open-source projects like Turbo and Svelte dropping TypeScript in favor of vanilla JavaScript? Learn about the pros and cons of TypeScript

#programming #javascript #thecodereport 

💬 Chat with Me on Discord

https://discord.gg/fireship

🔗 Resources

Turbo vs TypeScript https://world.hey.com/dhh/turbo-8-is-dropping-typescript-70165c01
Svelte Dropping TS https://news.ycombinator.com/item?id=35892250

🔥 Get More Content - Upgrade to PRO

Upgrade at https://fireship.io/pro
Use code YT25 for 25% off PRO access 

🎨 My Editor Settings

- Atom One Dark 
- vscode-icons
- Fira Code Font

🔖 Topics Covered

- TypeScript Benefits for web development
- TS vs JS
- Drawbacks of TypeScript
- Did Svelte stop using TypeScript?
- Does DHH hate TypeScript?
- Why TypeScript sucks
- Why TypeScript is awesome
2024-02-04T13:20:27.501Z
nova-2
2-general-nova
2024-01-09.29447
30089e05-99d1-4376-b32e-c263170674af
7278de28-36ba-45e1-ae91-6ee15f77c438
d61ea3200a761a5bda1ebdccd68319655d16fbbbc0536f5f50f472ae50a4eb4e
67875a7f-c9c4-48a0-aa55-5bdb8a91c34a
deprecated
It is September 7, 2023, and you are watching the code report.
In many years ago in 2017, legendary JavaScript user Kent c Dodds said, I don't use TypeScript, so I don't ever plan on supporting it.
In 2019, he goes on to say, your impassioned love of TypeScript is sort of freaking me out.
And finally in 2023 comes capitulation.
TypeScript is 1, and it's only a matter of time you're using it whether you like it or not.
But this is the sign of a good developer.
You have to be open minded and willing to adapt to new tools and sometimes tools you don't even like.
But the big question here is did TypeScript really win?
Because recently, the turns have started to table.
A bunch of big open source projects have decided to ditch TypeScript in favor of vanilla JavaScript.
To understand the shocking turn of events, we'll need to go back to the very beginning in 2012 when TypeScript c was first released by Microsoft.
Nobody really cared at first, but then a few years later, it was adopted by the Angular 2 framework, which everybody thought was crazy.
But here's the thing.
1st, they think you're crazy, then they fight you, then you change the world or you go to jail.
By the early 20 twenties, TypeScript was everywhere, at which point most of its haters had been converted into true believers.
But now right as we're about to reach the glorious climax of TypeScript saturation, you've got big libraries like Svelte, Drizzle, and Turbo deciding to ditch TypeScript from their code bases.
To be clear, that just means that they're not going to use TypeScript when developing in these libraries, but as an end user in a framework like Svelte, for example, you're still able to use TypeScript just like normal.
But how could anyone possibly go back to vanilla JS after using TypeScript?
Did they not remember runtime errors like cannot read properties of undefined?
Did they not remember how hard it is to refactor a code base where you have no idea what anything is?
Well, these People are a lot smarter than I am, so let's first look at this article from d h h, the creator of Ruby on Rails, who's getting rid of TypeScript in turbo version 8.
The main reason they're getting that is not because of the compile step, but rather because it pollutes the code with, quote, type gymnastics, and there's a lot of truth to that, especially when developing a library.
I'm working on a library myself called Svelte Fire, and as you can see in the code here, I have to do my own type gymnastics with TypeScript just to get rid of some red squiggly lines in the IDE.
Now I could simply replace this type with any and not get any type inference, but then my boss would yell at me.
He's a total who will abuse me emotionally and physically if I don't code up to its standards.
It's not easy being self employed.
Furthermore, I have the compiler in strict mode, which means I have to use any anytime I don't wanna use an c plus a type, and that results in code that's anything but beautiful.
Let's head over to turbo on GitHub and see how people are reacting to this change.
Well, it's blue dumpster fire, and a lot of developers are upset that their TS contributions are now dead on arrival.
But another huge project moving away from TypeScript is Svelte, and the reasoning is a bit different.
It's purely practical, and I recommend you read this post by Rich Harris.
Svelte 5, which may come out later this year, no longer uses TypeScript, and SvelteKit is already written in plain vanilla CIS, and the main benefit is no compile step, which is a huge boost in productivity for a large framework like this.
That may sound like total chaos for a large complex project, but they're actually still getting most of the benefits of TypeScript, but doing so with JSDoc, which is a standard comment format where you declare types and documentation with regular JavaScript comments that can then be used to generate types like a d dot ts file, and most importantly, provide IntelliSense in your editor so you know what the hell everything does and can catch bugs early just like you can with TypeScript.
That's the main reason I use TypeScript in the first place.
So is it time to just ditch it altogether?
Well, when it comes to building actual applications with a tool like Sveltekit or Next.
Js, s.
I don't see myself leaving TypeScript anytime soon.
Those tools integrate TS seamlessly, and trying to get the same results with JSDoc would be a total nightmare.
But one say, I hope we see the end of this holy war.
There's currently a stage 1 ECMAScript proposal that would add optional type annotations to JavaScript natively, thus making TypeScript nearly Siebelief.
This has been the CodeReport.
Thanks for watching, and I will see you in the next one.

Speaker 0: It is September 7, 2023, and you are watching the code report. In many years ago in 2017, legendary JavaScript user Kent c Dodds said, I don't use TypeScript, so I don't ever plan on supporting it. In 2019, he goes on to say, your impassioned love of TypeScript is sort of freaking me out. And finally in 2023 comes capitulation. TypeScript is 1, and it's only a matter of time you're using it whether you like it or not.

But this is the sign of a good developer. You have to be open minded and willing to adapt to new tools and sometimes tools you don't even like. But the big question here is did TypeScript really win? Because recently, the turns have started to table. A bunch of big open source projects have decided to ditch TypeScript in favor of vanilla JavaScript.

To understand the shocking turn of events, we'll need to go back to the very beginning in 2012 when TypeScript c was first released by Microsoft. Nobody really cared at first, but then a few years later, it was adopted by the Angular 2 framework, which everybody thought was crazy. But here's the thing. 1st, they think you're crazy, then they fight you, then you change the world or you go to jail. By the early 20 twenties, TypeScript was everywhere, at which point most of its haters had been converted into true believers.

But now right as we're about to reach the glorious climax of TypeScript saturation, you've got big libraries like Svelte, Drizzle, and Turbo deciding to ditch TypeScript from their code bases. To be clear, that just means that they're not going to use TypeScript when developing in these libraries, but as an end user in a framework like Svelte, for example, you're still able to use TypeScript just like normal. But how could anyone possibly go back to vanilla JS after using TypeScript? Did they not remember runtime errors like cannot read properties of undefined? Did they not remember how hard it is to refactor a code base where you have no idea what anything is?

Well, these People are a lot smarter than I am, so let's first look at this article from d h h, the creator of Ruby on Rails, who's getting rid of TypeScript in turbo version 8. The main reason they're getting that is not because of the compile step, but rather because it pollutes the code with, quote, type gymnastics, and there's a lot of truth to that, especially when developing a library. I'm working on a library myself called Svelte Fire, and as you can see in the code here, I have to do my own type gymnastics with TypeScript just to get rid of some red squiggly lines in the IDE. Now I could simply replace this type with any and not get any type inference, but then my boss would yell at me. He's a total who will abuse me emotionally and physically if I don't code up to its standards.

It's not easy being self employed. Furthermore, I have the compiler in strict mode, which means I have to use any anytime I don't wanna use an c plus a type, and that results in code that's anything but beautiful. Let's head over to turbo on GitHub and see how people are reacting to this change. Well, it's blue dumpster fire, and a lot of developers are upset that their TS contributions are now dead on arrival. But another huge project moving away from TypeScript is Svelte, and the reasoning is a bit different.

It's purely practical, and I recommend you read this post by Rich Harris. Svelte 5, which may come out later this year, no longer uses TypeScript, and SvelteKit is already written in plain vanilla CIS, and the main benefit is no compile step, which is a huge boost in productivity for a large framework like this. That may sound like total chaos for a large complex project, but they're actually still getting most of the benefits of TypeScript, but doing so with JSDoc, which is a standard comment format where you declare types and documentation with regular JavaScript comments that can then be used to generate types like a d dot ts file, and most importantly, provide IntelliSense in your editor so you know what the hell everything does and can catch bugs early just like you can with TypeScript. That's the main reason I use TypeScript in the first place. So is it time to just ditch it altogether?

Well, when it comes to building actual applications with a tool like Sveltekit or Next. Js, s. I don't see myself leaving TypeScript anytime soon. Those tools integrate TS seamlessly, and trying to get the same results with JSDoc would be a total nightmare. But one say, I hope we see the end of this holy war.

There's currently a stage 1 ECMAScript proposal that would add optional type annotations to JavaScript natively, thus making TypeScript nearly Siebelief. This has been the CodeReport. Thanks for watching, and I will see you in the next one.
It is September 7, 2023, and you are watching the code report. In many years ago in 2017, legendary JavaScript user Kent c Dodds said, I don't use TypeScript, so I don't ever plan on supporting it. In 2019, he goes on to say, your impassioned love of TypeScript is sort of freaking me out. And finally in 2023 comes capitulation. TypeScript is 1, and it's only a matter of time you're using it whether you like it or not. But this is the sign of a good developer. You have to be open minded and willing to adapt to new tools and sometimes tools you don't even like. But the big question here is did TypeScript really win? Because recently, the turns have started to table. A bunch of big open source projects have decided to ditch TypeScript in favor of vanilla JavaScript. To understand the shocking turn of events, we'll need to go back to the very beginning in 2012 when TypeScript c was first released by Microsoft. Nobody really cared at first, but then a few years later, it was adopted by the Angular 2 framework, which everybody thought was crazy. But here's the thing. 1st, they think you're crazy, then they fight you, then you change the world or you go to jail. By the early 20 twenties, TypeScript was everywhere, at which point most of its haters had been converted into true believers. But now right as we're about to reach the glorious climax of TypeScript saturation, you've got big libraries like Svelte, Drizzle, and Turbo deciding to ditch TypeScript from their code bases. To be clear, that just means that they're not going to use TypeScript when developing in these libraries, but as an end user in a framework like Svelte, for example, you're still able to use TypeScript just like normal. But how could anyone possibly go back to vanilla JS after using TypeScript? Did they not remember runtime errors like cannot read properties of undefined? Did they not remember how hard it is to refactor a code base where you have no idea what anything is? Well, these People are a lot smarter than I am, so let's first look at this article from d h h, the creator of Ruby on Rails, who's getting rid of TypeScript in turbo version 8. The main reason they're getting that is not because of the compile step, but rather because it pollutes the code with, quote, type gymnastics, and there's a lot of truth to that, especially when developing a library. I'm working on a library myself called Svelte Fire, and as you can see in the code here, I have to do my own type gymnastics with TypeScript just to get rid of some red squiggly lines in the IDE. Now I could simply replace this type with any and not get any type inference, but then my boss would yell at me. He's a total who will abuse me emotionally and physically if I don't code up to its standards.
It's not easy being self employed. Furthermore, I have the compiler in strict mode, which means I have to use any anytime I don't wanna use an c plus a type, and that results in code that's anything but beautiful. Let's head over to turbo on GitHub and see how people are reacting to this change.
programming
Well, it's blue dumpster fire, and a lot of developers are upset that their TS contributions are now dead on arrival. But another huge project moving away from TypeScript is Svelte, and the reasoning is a bit different. It's purely practical, and I recommend you read this post by Rich Harris. Svelte 5, which may come out later this year, no longer uses TypeScript, and SvelteKit is already written in plain vanilla CIS, and the main benefit is no compile step, which is a huge boost in productivity for a large framework like this. That may sound like total chaos for a large complex project, but they're actually still getting most of the benefits of TypeScript, but doing so with JSDoc, which is a standard comment format where you declare types and documentation with regular JavaScript comments that can then be used to generate types like a d dot ts file, and most importantly, provide IntelliSense in your editor so you know what the hell everything does and can catch bugs early just like you can with TypeScript. That's the main reason I use TypeScript in the first place. So is it time to just ditch it altogether? Well, when it comes to building actual applications with a tool like Sveltekit or Next. Js, s. I don't see myself leaving TypeScript anytime soon. Those tools integrate TS seamlessly, and trying to get the same results with JSDoc would be a total nightmare.
But one say, I hope we see the end of this holy war. There's currently a stage 1 ECMAScript proposal that would add optional type annotations to JavaScript natively, thus making TypeScript nearly Siebelief. This has been the CodeReport. Thanks for watching, and I will see you in the next one.
war
ideologies
It is September 7, 2023, and you are watching the code report. In many years ago in 2017, legendary JavaScript user Kent c Dodds said, I don't use TypeScript, so I don't ever plan on supporting it. In 2019, he goes on to say, your impassioned love of TypeScript is sort of freaking me out. And finally in 2023 comes capitulation. TypeScript is 1, and it's only a matter of time you're using it whether you like it or not. But this is the sign of a good developer. You have to be open minded and willing to adapt to new tools and sometimes tools you don't even like. But the big question here is did TypeScript really win? Because recently, the turns have started to table. A bunch of big open source projects have decided to ditch TypeScript in favor of vanilla JavaScript. To understand the shocking turn of events, we'll need to go back to the very beginning in 2012 when TypeScript c was first released by Microsoft. Nobody really cared at first, but then a few years later, it was adopted by the Angular 2 framework, which everybody thought was crazy. But here's the thing. 1st, they think you're crazy, then they fight you, then you change the world or you go to jail. By the early 20 twenties, TypeScript was everywhere, at which point most of its haters had been converted into true believers. But now right as we're about to reach the glorious climax of TypeScript saturation, you've got big libraries like Svelte, Drizzle, and Turbo deciding to ditch TypeScript from their code bases. To be clear, that just means that they're not going to use TypeScript when developing in these libraries, but as an end user in a framework like Svelte, for example, you're still able to use TypeScript just like normal. But how could anyone possibly go back to vanilla JS after using TypeScript? Did they not remember runtime errors like cannot read properties of undefined? Did they not remember how hard it is to refactor a code base where you have no idea what anything is? Well, these People are a lot smarter than I am, so let's first look at this article from d h h, the creator of Ruby on Rails, who's getting rid of TypeScript in turbo version 8. The main reason they're getting that is not because of the compile step, but rather because it pollutes the code with, quote, type gymnastics, and there's a lot of truth to that, especially when developing a library. I'm working on a library myself called Svelte Fire, and as you can see in the code here, I have to do my own type gymnastics with TypeScript just to get rid of some red squiggly lines in the IDE. Now I could simply replace this type with any and not get any type inference, but then my boss would yell at me. He's a total who will abuse me emotionally and physically if I don't code up to its standards. It's not easy being self employed. Furthermore, I have the compiler in strict mode, which means I have to use any anytime I don't wanna use an c plus a type, and that results in code that's anything but beautiful. Let's head over to turbo on GitHub and see how people are reacting to this change. Well, it's blue dumpster fire, and a lot of developers are upset that their TS contributions are now dead on arrival. But another huge project moving away from TypeScript is Svelte, and the reasoning is a bit different. It's purely practical, and I recommend you read this post by Rich Harris. Svelte 5, which may come out later this year, no longer uses TypeScript, and SvelteKit is already written in plain vanilla CIS, and the main benefit is no compile step, which is a huge boost in productivity for a large framework like this. That may sound like total chaos for a large complex project, but they're actually still getting most of the benefits of TypeScript, but doing so with JSDoc, which is a standard comment format where you declare types and documentation with regular JavaScript comments that can then be used to generate types like a d dot ts file, and most importantly, provide IntelliSense in your editor so you know what the hell everything does and can catch bugs early just like you can with TypeScript. That's the main reason I use TypeScript in the first place. So is it time to just ditch it altogether? Well, when it comes to building actual applications with a tool like Sveltekit or Next. Js, s. I don't see myself leaving TypeScript anytime soon. Those tools integrate TS seamlessly, and trying to get the same results with JSDoc would be a total nightmare. But one say, I hope we see the end of this holy war. There's currently a stage 1 ECMAScript proposal that would add optional type annotations to JavaScript natively, thus making TypeScript nearly Siebelief. This has been the CodeReport. Thanks for watching, and I will see you in the next one.
It
it
is
is
September
september
7,
7
2023,
2023
and
and
you
you
are
are
watching
watching
the
the
code
code
report.
report
In
in
many
many
years
years
ago
ago
in
in
2017,
2017
legendary
legendary
JavaScript
javascript
user
user
Kent
kent
c
c
Dodds
dodds
said,
said
I
i
don't
don't
use
use
TypeScript,
typescript
so
so
I
i
don't
don't
ever
ever
plan
plan
on
on
supporting
supporting
it.
it
In
in
2019,
2019
he
he
goes
goes
on
on
to
to
say,
say
your
your
impassioned
impassioned
love
love
of
of
TypeScript
typescript
is
is
sort
sort
of
of
freaking
freaking
me
me
out.
out
And
and
finally
finally
in
in
2023
2023
comes
comes
capitulation.
capitulation
TypeScript
typescript
is
is
1,
1
and
and
it's
it's
only
only
a
a
matter
matter
of
of
time
time
you're
you're
using
using
it
it
whether
whether
you
you
like
like
it
it
or
or
not.
not
But
but
this
this
is
is
the
the
sign
sign
of
of
a
a
good
good
developer.
developer
You
you
have
have
to
to
be
be
open
open
minded
minded
and
and
willing
willing
to
to
adapt
adapt
to
to
new
new
tools
tools
and
and
sometimes
sometimes
tools
tools
you
you
don't
don't
even
even
like.
like
But
but
the
the
big
big
question
question
here
here
is
is
did
did
TypeScript
typescript
really
really
win?
win
Because
because
recently,
recently
the
the
turns
turns
have
have
started
started
to
to
table.
table
A
a
bunch
bunch
of
of
big
big
open
open
source
source
projects
projects
have
have
decided
decided
to
to
ditch
ditch
TypeScript
typescript
in
in
favor
favor
of
of
vanilla
vanilla
JavaScript.
javascript
To
to
understand
understand
the
the
shocking
shocking
turn
turn
of
of
events,
events
we'll
we'll
need
need
to
to
go
go
back
back
to
to
the
the
very
very
beginning
beginning
in
in
2012
2012
when
when
TypeScript
typescript
c
c
was
was
first
first
released
released
by
by
Microsoft.
microsoft
Nobody
nobody
really
really
cared
cared
at
at
first,
first
but
but
then
then
a
a
few
few
years
years
later,
later
it
it
was
was
adopted
adopted
by
by
the
the
Angular
angular
2
2
framework,
framework
which
which
everybody
everybody
thought
thought
was
was
crazy.
crazy
But
but
here's
here's
the
the
thing.
thing
1st,
1st
they
they
think
think
you're
you're
crazy,
crazy
then
then
they
they
fight
fight
you,
you
then
then
you
you
change
change
the
the
world
world
or
or
you
you
go
go
to
to
jail.
jail
By
by
the
the
early
early
20
20
twenties,
twenties
TypeScript
typescript
was
was
everywhere,
everywhere
at
at
which
which
point
point
most
most
of
of
its
its
haters
haters
had
had
been
been
converted
converted
into
into
true
true
believers.
believers
But
but
now
now
right
right
as
as
we're
we're
about
about
to
to
reach
reach
the
the
glorious
glorious
climax
climax
of
of
TypeScript
typescript
saturation,
saturation
you've
you've
got
got
big
big
libraries
libraries
like
like
Svelte,
svelte
Drizzle,
drizzle
and
and
Turbo
turbo
deciding
deciding
to
to
ditch
ditch
TypeScript
typescript
from
from
their
their
code
code
bases.
bases
To
to
be
be
clear,
clear
that
that
just
just
means
means
that
that
they're
they're
not
not
going
going
to
to
use
use
TypeScript
typescript
when
when
developing
developing
in
in
these
these
libraries,
libraries
but
but
as
as
an
an
end
end
user
user
in
in
a
a
framework
framework
like
like
Svelte,
svelte
for
for
example,
example
you're
you're
still
still
able
able
to
to
use
use
TypeScript
typescript
just
just
like
like
normal.
normal
But
but
how
how
could
could
anyone
anyone
possibly
possibly
go
go
back
back
to
to
vanilla
vanilla
JS
js
after
after
using
using
TypeScript?
typescript
Did
did
they
they
not
not
remember
remember
runtime
runtime
errors
errors
like
like
cannot
cannot
read
read
properties
properties
of
of
undefined?
undefined
Did
did
they
they
not
not
remember
remember
how
how
hard
hard
it
it
is
is
to
to
refactor
refactor
a
a
code
code
base
base
where
where
you
you
have
have
no
no
idea
idea
what
what
anything
anything
is?
is
Well,
well
these
these
People
people
are
are
a
a
lot
lot
smarter
smarter
than
than
I
i
am,
am
so
so
let's
let's
first
first
look
look
at
at
this
this
article
article
from
from
d
d
h
h
h,
h
the
the
creator
creator
of
of
Ruby
ruby
on
on
Rails,
rails
who's
who's
getting
getting
rid
rid
of
of
TypeScript
typescript
in
in
turbo
turbo
version
version
8.
8
The
the
main
main
reason
reason
they're
they're
getting
getting
that
that
is
is
not
not
because
because
of
of
the
the
compile
compile
step,
step
but
but
rather
rather
because
because
it
it
pollutes
pollutes
the
the
code
code
with,
with
quote,
quote
type
type
gymnastics,
gymnastics
and
and
there's
there's
a
a
lot
lot
of
of
truth
truth
to
to
that,
that
especially
especially
when
when
developing
developing
a
a
library.
library
I'm
i'm
working
working
on
on
a
a
library
library
myself
myself
called
called
Svelte
svelte
Fire,
fire
and
and
as
as
you
you
can
can
see
see
in
in
the
the
code
code
here,
here
I
i
have
have
to
to
do
do
my
my
own
own
type
type
gymnastics
gymnastics
with
with
TypeScript
typescript
just
just
to
to
get
get
rid
rid
of
of
some
some
red
red
squiggly
squiggly
lines
lines
in
in
the
the
IDE.
ide
Now
now
I
i
could
could
simply
simply
replace
replace
this
this
type
type
with
with
any
any
and
and
not
not
get
get
any
any
type
type
inference,
inference
but
but
then
then
my
my
boss
boss
would
would
yell
yell
at
at
me.
me
He's
he's
a
a
total
total
who
who
will
will
abuse
abuse
me
me
emotionally
emotionally
and
and
physically
physically
if
if
I
i
don't
don't
code
code
up
up
to
to
its
its
standards.
standards
It's
it's
not
not
easy
easy
being
being
self
self
employed.
employed
Furthermore,
furthermore
I
i
have
have
the
the
compiler
compiler
in
in
strict
strict
mode,
mode
which
which
means
means
I
i
have
have
to
to
use
use
any
any
anytime
anytime
I
i
don't
don't
wanna
wanna
use
use
an
an
c
c
plus
plus
a
a
type,
type
and
and
that
that
results
results
in
in
code
code
that's
that's
anything
anything
but
but
beautiful.
beautiful
Let's
let's
head
head
over
over
to
to
turbo
turbo
on
on
GitHub
github
and
and
see
see
how
how
people
people
are
are
reacting
reacting
to
to
this
this
change.
change
Well,
well
it's
it's
blue
blue
dumpster
dumpster
fire,
fire
and
and
a
a
lot
lot
of
of
developers
developers
are
are
upset
upset
that
that
their
their
TS
ts
contributions
contributions
are
are
now
now
dead
dead
on
on
arrival.
arrival
But
but
another
another
huge
huge
project
project
moving
moving
away
away
from
from
TypeScript
typescript
is
is
Svelte,
svelte
and
and
the
the
reasoning
reasoning
is
is
a
a
bit
bit
different.
different
It's
it's
purely
purely
practical,
practical
and
and
I
i
recommend
recommend
you
you
read
read
this
this
post
post
by
by
Rich
rich
Harris.
harris
Svelte
svelte
5,
5
which
which
may
may
come
come
out
out
later
later
this
this
year,
year
no
no
longer
longer
uses
uses
TypeScript,
typescript
and
and
SvelteKit
sveltekit
is
is
already
already
written
written
in
in
plain
plain
vanilla
vanilla
CIS,
cis
and
and
the
the
main
main
benefit
benefit
is
is
no
no
compile
compile
step,
step
which
which
is
is
a
a
huge
huge
boost
boost
in
in
productivity
productivity
for
for
a
a
large
large
framework
framework
like
like
this.
this
That
that
may
may
sound
sound
like
like
total
total
chaos
chaos
for
for
a
a
large
large
complex
complex
project,
project
but
but
they're
they're
actually
actually
still
still
getting
getting
most
most
of
of
the
the
benefits
benefits
of
of
TypeScript,
typescript
but
but
doing
doing
so
so
with
with
JSDoc,
jsdoc
which
which
is
is
a
a
standard
standard
comment
comment
format
format
where
where
you
you
declare
declare
types
types
and
and
documentation
documentation
with
with
regular
regular
JavaScript
javascript
comments
comments
that
that
can
can
then
then
be
be
used
used
to
to
generate
generate
types
types
like
like
a
a
d
d
dot
dot
ts
ts
file,
file
and
and
most
most
importantly,
importantly
provide
provide
IntelliSense
intellisense
in
in
your
your
editor
editor
so
so
you
you
know
know
what
what
the
the
hell
hell
everything
everything
does
does
and
and
can
can
catch
catch
bugs
bugs
early
early
just
just
like
like
you
you
can
can
with
with
TypeScript.
typescript
That's
that's
the
the
main
main
reason
reason
I
i
use
use
TypeScript
typescript
in
in
the
the
first
first
place.
place
So
so
is
is
it
it
time
time
to
to
just
just
ditch
ditch
it
it
altogether?
altogether
Well,
well
when
when
it
it
comes
comes
to
to
building
building
actual
actual
applications
applications
with
with
a
a
tool
tool
like
like
Sveltekit
sveltekit
or
or
Next.
next
Js,
js
s.
s
I
i
don't
don't
see
see
myself
myself
leaving
leaving
TypeScript
typescript
anytime
anytime
soon.
soon
Those
those
tools
tools
integrate
integrate
TS
ts
seamlessly,
seamlessly
and
and
trying
trying
to
to
get
get
the
the
same
same
results
results
with
with
JSDoc
jsdoc
would
would
be
be
a
a
total
total
nightmare.
nightmare
But
but
one
one
say,
say
I
i
hope
hope
we
we
see
see
the
the
end
end
of
of
this
this
holy
holy
war.
war
There's
there's
currently
currently
a
a
stage
stage
1
1
ECMAScript
ecmascript
proposal
proposal
that
that
would
would
add
add
optional
optional
type
type
annotations
annotations
to
to
JavaScript
javascript
natively,
natively
thus
thus
making
making
TypeScript
typescript
nearly
nearly
Siebelief.
siebelief
This
this
has
has
been
been
the
the
CodeReport.
codereport
Thanks
thanks
for
for
watching,
watching
and
and
I
i
will
will
see
see
you
you
in
in
the
the
next
next
one.
one
success
In this video, the speaker discusses the use of TypeScript in building websites and apps, highlighting the benefits it provides, including productivity and fast development. They also mention a post from Rich Harris on Svelte Fire, which adds optional TypeScript to JavaScript natively, making it a "teen war." The speaker concludes that TypeScript is a must for developers, and they will continue to use it in the future.
Big projects are ditching TypeScript… why?
It is September 7, 2023, and you are watching the code report. In many years ago in 2017, legendary JavaScript user Kent c Dodds said, I don't use TypeScript, so I don't ever plan on supporting it. In 2019, he goes on to say, your impassioned love of TypeScript is sort of freaking me out. And finally in 2023 comes capitulation. TypeScript is 1, and it's only a matter of time you're using it whether you like it or not. But this is the sign of a good developer. You have to be open minded and willing to adapt to new tools and sometimes tools you don't even like. But the big question here is did TypeScript really win? Because recently, the turns have started to table. A bunch of big open source projects have decided to ditch TypeScript in favor of vanilla JavaScript. To understand the shocking turn of events, we'll need to go back to the very beginning in 2012 when TypeScript c was first released by Microsoft. Nobody really cared at first, but then a few years later, it was adopted by the Angular 2 framework, which everybody thought was crazy. But here's the thing. 1st, they think you're crazy, then they fight you, then you change the world or you go to jail. By the early 20 twenties, TypeScript was everywhere, at which point most of its haters had been converted into true believers. But now right as we're about to reach the glorious climax of TypeScript saturation, you've got big libraries like Svelte, Drizzle, and Turbo deciding to ditch TypeScript from their code bases. To be clear, that just means that they're not going to use TypeScript when developing in these libraries, but as an end user in a framework like Svelte, for example, you're still able to use TypeScript just like normal. But how could anyone possibly go back to vanilla JS after using TypeScript? Did they not remember runtime errors like cannot read properties of undefined? Did they not remember how hard it is to refactor a code base where you have no idea what anything is? Well, these People are a lot smarter than I am, so let's first look at this article from d h h, the creator of Ruby on Rails, who's getting rid of TypeScript in turbo version 8. The main reason they're getting that is not because of the compile step, but rather because it pollutes the code with, quote, type gymnastics, and there's a lot of truth to that, especially when developing a library. I'm working on a library myself called Svelte Fire, and as you can see in the code here, I have to do my own type gymnastics with TypeScript just to get rid of some red squiggly lines in the IDE. Now I could simply replace this type with any and not get any type inference, but then my boss would yell at me. He's a total who will abuse me emotionally and physically if I don't code up to its standards. It's not easy being self employed. Furthermore, I have the compiler in strict mode, which means I have to use any anytime I don't wanna use an c plus a type, and that results in code that's anything but beautiful. Let's head over to turbo on GitHub and see how people are reacting to this change. Well, it's blue dumpster fire, and a lot of developers are upset that their TS contributions are now dead on arrival. But another huge project moving away from TypeScript is Svelte, and the reasoning is a bit different. It's purely practical, and I recommend you read this post by Rich Harris. Svelte 5, which may come out later this year, no longer uses TypeScript, and SvelteKit is already written in plain vanilla CIS, and the main benefit is no compile step, which is a huge boost in productivity for a large framework like this. That may sound like total chaos for a large complex project, but they're actually still getting most of the benefits of TypeScript, but doing so with JSDoc, which is a standard comment format where you declare types and documentation with regular JavaScript comments that can then be used to generate types like a d dot ts file, and most importantly, provide IntelliSense in your editor so you know what the hell everything does and can catch bugs early just like you can with TypeScript. That's the main reason I use TypeScript in the first place. So is it time to just ditch it altogether? Well, when it comes to building actual applications with a tool like Sveltekit or Next. Js, s. I don't see myself leaving TypeScript anytime soon. Those tools integrate TS seamlessly, and trying to get the same results with JSDoc would be a total nightmare. But one say, I hope we see the end of this holy war. There's currently a stage 1 ECMAScript proposal that would add optional type annotations to JavaScript natively, thus making TypeScript nearly Siebelief. This has been the CodeReport. Thanks for watching, and I will see you in the next one.
In this video, the speaker discusses the use of TypeScript in building websites and apps, highlighting the benefits it provides, including productivity and fast development. They also mention a post from Rich Harris on Svelte Fire, which adds optional TypeScript to JavaScript natively, making it a "teen war." The speaker concludes that TypeScript is a must for developers, and they will continue to use it in the future.