host angularjs with s3 and cloudfront

For SPA application like AngularJS project, it’s easy to use s3 to host it. But if you want to use SSL, you have to use CloudFront for help, because S3 doesn’t support SSL directly. But there is some special issue to solve when you host AngularJS project, such as url issue for html5mode and enable SSL for CloudFront.

angularjs2.0

AngularJS 2.0 is coming, even is still in beta and something is still changing, but most stuff works well. It’s a good time to start to try it. In our recent demo we find its Component is very cool.

Interview Questions

Recent days knows a lot of interview questions, some of them are interesting.

Learn React.js

Finally have chance to learn React.js, because we need choose one from Angular.js 2 and React.js. To learn React.js, I find some good articles to start.

Toptal is funny

Toptal is a freelencer site which provides top 3% web freelencers. To join it, you have to pass their test first. There are a lot of people waiting to join it, so you have to wait for some time until some screener will come to talk and interview you. If want to get priority, you have to do something like what I’m doing right now, writing a blog about Toptal, to show you’re eager to join it, and it’s so great to join it. So everyone read this blog is moved to join it.

Emacs yasnippet

Emacs yasnippet provides a lot of snippets for different program language, even markdown file. Also you can add your snippets if you like. For example, when I write blog with code, I don’t want to enter “{% highlight javascript %} {% endhighlight %}” everytime, with yasnippet help, I just need enter highlight then press ‘Tab’, the highlight snippet code is generated automatically.

Babel Tutorial For NodeJS

Babel.js is a js compiler which translates ES6 to ES5 which is implemented by all moreden browsers. Actually babel.js should be gone when ES6 is supported by most browsers. But before that, babel.js can help us to use ES6 new features before that happens. Why do we need use ES6 features right now? Because ES6 make our life easier for javascript.

BlockAd on iOS

Check my first iOS app BlockAd, which is based on ionic. You can use it block ads on ios app and web browser. Also you can access Chinese video/music sites when you are aboard, such as Youku, Sina video, Sohu video and Xiami. Thanks Unblock Youku.

redshift disk full

Today fail to copy data from s3 json file to redshift, check the stl_error and stl_load_errors tables, I find some error like “disk full error”. Also I check the redshift aws console, I find the Percentage of Disk Usage is 100%.

iOS html5 video

Some iOS html5 video experience. Actually I spent much time to handle some special cases for iOS html5 video element, but always forget after finishing my work. Next time I need to spend time to figure out the same issue. Now blog it to avoid to forget it again :)