Shopee / shopee-react-knowledgeable

⚛︎ To share knowledge and have fun.
78 stars 19 forks source link

🧸 Implement a Toy Web Browser #213

Closed jzhang026 closed 4 years ago

jzhang026 commented 4 years ago

speaker

Adrian

intro

Once upon a time, an interviewer asked me what all happens behind the scenes from the time a URL was typed in the browser to the time when the page was shown on the screen. and if you search the question on Google, you may see quite a lot of answers, and the focus of each answer is different.

I recently built a toy browser with javascript, which tries to render an HTML string into an image. Along the process, I got a deep understanding of how browser rendering works. Feature of the toy browser:

  1. parse HTTP response
  2. construct the DOM tree with the returned HTML string
  3. Compute CSS and match CSS rules with DOM
  4. calculate the layout.
  5. render an image described by the HTML string.

resources

Scheduling

wgao19 commented 4 years ago

Hey @jzhang026 thanks again for this talk! Here's the link to the video recording of the talk: https://youtu.be/WRgeNqVZXEU

(sorry I forgot to hit "record" at the very beginning therefore the front part was cut off.. in the live stream playback, can still see the full talk)