三歲小朋友也能懂的 Vue watch 清理副作用 (clean up) 1. watch 是什麼? 小朋友,你有沒有玩過「聽寫遊戲」呢?當老師說一個字,你就要寫下來對不對? 在 Vue 裡,watch 就像是在「聽」一個變數的變化。只要變數變了,它就會「做一些事情」,例如去網路上抓新的圖片。 2. 什麼是「過期的副作用」? 現在想像一下,你在畫畫,老師叫你畫「小貓」,你開始畫。但畫到一半,老師又說:「換畫小狗!」然後又說:「換畫小兔子!」結果,你的畫紙上畫滿了不同動物,亂七八糟的,對吧? 在 ...
Developer, building thins on web.
I was the main web front-end engineer responsible for developing and maintaining the customer-facing platform for WisdomHall (品學堂) in 2024 Q3 Q4, code reviewed by CTO and a senior engineer. http://learning.wisdomhall.com.tw has total active 257k users, according to their Facebook post: https://www.facebook.com/share/p/1MnjbwZxCV/ My tech stack includes JavaScript, Vue 2, Nuxt 2, git, and Docker.
Markdown supported · ⌘↵ to post
No responses yet.