Dockerfile for a rapid Dokku deployment

How to create your own Dockerfile for a rapid Dokku deployment

Dokku is good, and I wrote a blog for whole setup of Dokku + Node + React + MongoDB. This blog, we will address the issue where if you use the default buildpack for building, it will download Node and NPM everytime, which will make it very long in some circumstance, in this blog, we will Dockerfile to replace it, make…

jsx in TypeScript

How to do generic type transferring with jsx in TypeScript

So I just encountered a problem where I want to make a better type checking in a props of a React component. It’s about one prop takes an array of certain type X, and in another prop: callback, this type X needs to be the parameter of the callback. Let’s see how to do that in TypeScript.

nested level using mobx-state-tree

How to make nested level using mobx-state-tree

I’ve heard mobx-state-tree for a while. Today I looked into it, and found it’s pretty lovely. Kind of the fat model pattern. Where it could make the code much more cleaner and far more less boilerplate compare to redux. Today, let’s see how to make nested level in mobx-state-tree.

How to pass css class as prop using

How to pass css class as prop using styled component

Styled components will be good if you use it from start, but things could be tricky in terms of mixing it up with other libraries or even your own code. Today, I will show you how to use styled components to generate css class and pass it to the 3rd party lib or your own…

© 2025 www.albertgao.xyz | All Rights Reserved.