Fireship · @fireship

a fresh new web framework is out

Uploaded June 29, 2022 · Length 3:25

a fresh new web framework is out

Summary

fresh web framework review: zero js to browser, server-side rendering, typescript support, island's architecture, dino deploy

  • fresh web framework
  • zero js to browser
  • server-side rendering
  • typescript support
  • islands architecture
  • dino deploy

Transcript preview

The first 2 minutes of the transcript. Select a timestamp to watch that moment on YouTube.

  1. 0:01

    it is june 29 2022 and you're watching

  2. 0:04

    the code report well it's that time of

  3. 0:06

    the week again a fresh new web framework

  4. 0:08

    has been born and i know exactly what

  5. 0:10

    you're

  6. 0:15

    do thinking anymore it's name is

  7. 0:17

    fresh and it's dripping like literally

  8. 0:19

    the logo is dripping but more

  9. 0:21

    importantly it has some awesome features

  10. 0:23

    it ships zero javascript to the browser

  11. 0:25

    by default has no build step during

  12. 0:26

    development and is based on the island's

  13. 0:28

    architecture which i'll explain in

  14. 0:30

    detail in just a minute fresh is a full

  15. 0:32

    stack framework for server-side

  16. 0:33

    rendering like ruby on rails or laravel

  17. 0:36

    but you write your apps in typescript

  18. 0:37

    because it's built on top of dino which

  19. 0:39

    if you don't know is a javascript

  20. 0:41

    runtime alternative to node.js dino was

  21. 0:43

    created by ryan dull the same guy who

  22. 0:45

    created node.js because he wasn't

  23. 0:47

    totally happy with the way things turned

  24. 0:48

    out the first time and it's my fault and

  25. 0:50

    i'm very sorry and unfortunately it's

  26. 0:53

    impossible to undo now it is officially

  27. 0:56

    pronounced dino and not deno as i messed

  28. 0:58

    up in this video but the benefit of

  29. 1:00

    using it for a web framework is that you

  30. 1:01

    get first class typescript support out

  31. 1:03

    of the box in addition you can build and

  32. 1:05

    deploy your app without a build step

  33. 1:07

    while most javascript developers are

  34. 1:08

    bragging about increasing build times by

  35. 1:10

    10 percent dino developers just don't

  36. 1:12

    even have a build step fresh can be

  37. 1:14

    deployed to the edge instantly with dino

  38. 1:15

    deploy the simplicity here is really

  39. 1:17

    awesome one drawback though is that dino

  40. 1:19

    has a much smaller ecosystem when

  41. 1:21

    compared to node.js and not all npm

  42. 1:23

    packages are compatible the most

  43. 1:25

    interesting thing about fresh though is

  44. 1:26

    that it's based on the island's

  45. 1:28

    architecture which is also known as

  46. 1:30

    partial hydration the idea is that you

  47. 1:32

    build a website using a javascript

  48. 1:33

    framework in this case fresh uses preact

  49. 1:36

    for the ui but instead of sending

  50. 1:37

    javascript code to the browser you

  51. 1:39

    render everything to static html on the

  52. 1:42

    server that means by default the only

  53. 1:43

    thing the end user gets is a static html

  54. 1:46

    page which is much faster for the

  55. 1:47

    browser to load and render in many cases

  56. 1:50

    though a website will need more

  57. 1:51

    interactivity than just static html and

  58. 1:54

    that's where islands come in but first

  59. 1:55

    respect to jason miller who's the first

  60. 1:57

    person to describe the island's

  61. 1:58

    architecture and also the creator of the