タグ

ブックマーク / blog.64p.org (6)

  • AngularJS を本気でつかうための tips - tokuhirom's blog

    最近、管理画面で AngularJS をつかってみている。 そんな中で、いくつか工夫した点があるのでそれをシェアさせていただきます。 XHR のエラーを表示する XHR のエラーがおきた際のハンドリングをいちいち手でかくのは非効率。管理画面とか中の人しかつかわないので、エラーがおこった旨を随時報告するだけでよい。 そんなケースでは以下のようにする。 angular.module('myapp.exceptionHandler', []) .config(['$httpProvider', function ($httpProvider) { $httpProvider.interceptors.push(function($q, $log, $rootScope) { return { 'responseError': function(response) { $log.error(res

  • tmux で画面の外に |----------------- ってでまくるときの対策 - tokuhirom's blog

    tmux a -dでいいと typester さんにおしえてもらいました。 killall tmux などの残虐な手段もおしえられましたが、人道的な解決に成功いたしました。

    yamkazu
    yamkazu 2013/04/28
    tmuxで画面の外に |-----------------と出たときの対処法
  • httpstatus コマンドで、HTTP のステータスコードをすばやくしらべる! - tokuhirom's blog

    一般的な Web Programmer ならば、HTTP Status code はすべて暗記していると聞きました。 しかし、僕は初心者なので、なかなか覚えきれていないので、HTTPのステータスコードをさがすのに便利なツールを用意しました。App::httpstatus です。インストール方法は cpanm App::httpstatus です。というか依存とかないのでhttp://api.metacpan.org/source/TOKUHIROM/App-httpstatus-v1.0.0/httpstatus をコピーしてくればうごきます。 使い方は以下のとおりです。 4xx なコードを列挙する。 % httpstatus 4 400 Bad Request 401 Unauthorized 402 Payment Required 403 Forbidden 404 Not Foun

    yamkazu
    yamkazu 2013/02/23
  • node.js で人気のあるライブラリ10選 - tokuhirom's blog

    node.js というか npm で依存されているライブラリの上位10個ぐらいがどういうものがはいっているのかをまとめます! 具体的には serach.npmjs.org の Most depends on にのっているリストに註釈をつけただけです! http://search.npmjs.org/ 1位 underscore.js 392個http://search.npmjs.org/#/underscore クライアントサイド JS で人気のたかいユーティリティーライブラリの underscore.js が堂々の第1位。 クライアントサイドでつかってるからそのままつかってる人が多いのかな、とおもっています。

  • tokuhirom blog

    Blog Search when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: ${entry.path} [in template "__entry.ftlh" at line 3, column 25] - Reached through: #include "__entry.ftlh" [in template "entry.ftlh" at

  • tokuhirom blog

    Blog Search when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: ${entry.path} [in template "__entry.ftlh" at line 3, column 25] - Reached through: #include "__entry.ftlh" [in template "entry.ftlh" at

    yamkazu
    yamkazu 2008/05/22
    脱初心者の情報が整理されていないのは、Perlに限ったことじゃなくて他の言語でもいえたりするかな。
  • 1