WebStorm: Fix js syntax highlighting.

When I use WebStorm 7.0.3, sometimes the editor for JavaScript shows me wrong syntax highlighting or coloring. This can be fixed mostly with adding some annotations to tell the editor meaning of the code. But unfortunately, the problem cannot be fixed on this way, infrequently. In this case, I fix as follows, Open the project which has this problem. Click ‘File’ -> ‘Invalidate Caches/Restart…’ Click [Invalidate and Restart] button when opened the dialog.

ClosureCompiler

Closureで型キャストのやり方。 function makeInstance(clazz) { var instance = /**@type {Type}*/(new clazz()); .... return instance; } この場合括弧が必要なので注意。

Closure覚書

ClosureでAdvanced Optimizationsに対応する場合にいろいろ調べたこと覚書。