Fireship · @fireship
SvelteKit is my mistress
Uploaded December 15, 2022 · Length 4:19
Summary
Fireship reviews SvelteKit, a full stack framework for UI development, highlighting its features and developer experience.
- sveltekit
- javascript framework
- full stack development
- ui library
- server rendering
Transcript preview
The first 2 minutes of the transcript. Select a timestamp to watch that moment on YouTube.
- 0:01
it is December 15 2022 and you're
- 0:04
watching the code report after what felt
- 0:06
like a lifetime of waiting spelled kit
- 0:08
officially hit version 1.0 yesterday
- 0:10
which is a full stack framework for the
- 0:12
world's most loved UI Library when I
- 0:14
tried spell for the first time over
- 0:15
three years ago it left me extremely
- 0:17
titillated it had an Innovative compiler
- 0:19
elegant reactivity and we just had so
- 0:21
much fun together
- 0:23
as the years went on I continued working
- 0:25
with react and angular but truth be told
- 0:28
I would often close my eyes and pretend
- 0:30
that they were actually spell I was web
- 0:31
developmentally frustrated but luckily
- 0:34
just in time for Christmas we've
- 0:35
achieved a glorious climax that makes it
- 0:37
possible to use felt in a
- 0:39
server-rendered application let's take a
- 0:40
look at some code and see if it lives up
- 0:42
to all of these innuendos spelled kit is
- 0:44
very similar to other JavaScript meta
- 0:46
Frameworks Like nextjs Remix and nuxt
- 0:49
like next js13 it uses file system
- 0:52
routing but made a somewhat
- 0:53
controversial decision of using reserved
- 0:56
names to represent different types of UI
- 0:58
like page layout loading and error in
- 1:00
addition any file that has significance
- 1:02
to the framework is prefixed with a plus
- 1:04
sign there's been a lot of discussion
- 1:06
around this approach and not everybody
- 1:07
likes it because you end up with tons of
- 1:09
files in the project with the exact same
- 1:11
name which can lead to migraines if you
- 1:13
expand all the directories in your
- 1:14
editor on the other hand though these
- 1:16
conventions keep your project clear and
- 1:18
consistent page.spelt contains a
- 1:20
component that will be server rendered
- 1:22
when you navigate to that route after
- 1:23
the initial page load it will hydrate
- 1:25
and then the client-side router takes
- 1:27
over from there this is what we call SSR
- 1:29
and I think it's the most sensible
- 1:30
default however in spelled kit you can
- 1:32
mix and match other rendering strategies
- 1:34
like you can pre-render static HTML for
- 1:37
Jam stack style websites or if no server
- 1:39
is required you can use client rendering
- 1:41
to do everything in the browser or on
- 1:43
the flip side if you don't want any
- 1:44
JavaScript at all you can render
- 1:46
everything on the server like a
- 1:47
traditional multi-page application
- 1:49
what's awesome though is that you can
- 1:50
choose the best rendering strategy for a
- 1:52
page with a simple configuration option
- 1:54
you're not locked into just one
- 1:56
rendering Paradigm that's awesome but
- 1:58
the other big thing you'll want to know
- 1:59
about the developer experience is how


