- 起因因为上次写博客是在两年前了, 再上次是四年前, 本博客其实有很多组件都慢慢的不工作了, 本来以为只是小小的检修一下即可, 结果发现还是做了不少事情的, 感觉值得记录一下.
主旨Outdated Dependencies博客是利用hexo...
- wow 又是两年没写博客了… :( 最近被家属激励, 准备再次复活这个博客! 希望这次能坚持!
也是因为好久没用了, 发现了博客上好多部件都没法用了… 花了点时间更新了一下, 把失效的部分都替换了一下, 其中就有评论组件, 之前一直用的多说...
- JavaScript is a loosely typed language which means it doesn’t care type too much. Most times, it can convert different types automatically for us. But sometimes, you may actually need to know the exact type of a variable. And you may have trouble to do that in JS…
(We will only focus on normal types, a lot new types in...
TaoAlphatechjstype check Sa, August 27, 201616 minutes to read - Deep Copy vs Reference CopyIn javascript, everytime you use = or pass a primitive to a function, you are doing deep copy, since whatever happends to it will never affect the origin one.
But things will be so different on objects:
123456789101112131415161718192021// deep copy on primitiveslet a = "hello";let b = a;b = 1...
TaoAlphatechjscopy Sa, August 13, 20168 minutes to read - HistoryLike brianleroux said in his post ES6 Modules: The End of Civilization As We Know It?: “For many years JS had a single widely accepted module format, which is to say, there was none. Everything was a global variable petulantly hanging off the window object.”
Before we have CommonJS, AMD and the newest ES6 module...
TaoAlphatechjsmodule Fr, June 17, 20169 minutes to read - Write AheadAbout 30 minutes ago, I tried to rewrite the colors module, at least part of it :). Then I found a nice and rarely used method defineProperty which made the past 30 minutes totally worth it.
Rewrite the colorsBefore we put our hands on defineProperty, I want to tell you how I found this method :) colors is a...
TaoAlphatechjs Fr, April 29, 20167 minutes to read - Write AheadES6 introduces a new primitive type into JavaScript which is Symbol. All symbols are unique so you can treat them as tokens server as unique id.
You can create a symbol using its factory function Symbol(), you can pass a parameter to it as the name of the symbol, but most of time, the name is only used to de...
TaoAlphatechjses6symbol Th, April 28, 20169 minutes to read - Write aheadAfter we knew some basic ideas and commands of Docker (No? see Docker 101 self-learning tutorial). We can build our own docker images and customized our dev kit.
Today I will show you how to use Dockerfile build your own images, here I build a minimalist web dev image as example:
Let’s codeDockerfileDockerfi...
TaoAlphatechdocker We, April 27, 201615 minutes to read - Write AheadI start learning React recently, and since I haven’t written Angular code for several weeks, I guess I need to review some basic concepts during the self-learning :)
The first book which I am reading is Mastering React, it is pretty good, and I think if you want to learn React, you can start from this one.
D...
TaoAlphatechdata binding Fr, April 22, 20168 minutes to read - StoryYesterday, I got a question from a friend who asked me to review his code and explain why the object he printed out got changed before he actually modifies it. This is a classic ‘asynchronous’ or lazy evaluation(more accuarately) problem of console.log().
We all know that console.log is the most popular and common...
TaoAlphatechjs Th, April 21, 20167 minutes to read