Saturday, June 28, 2014

Yeoman Backbone generator: scaffolding has been broken

壊れててまともに動かない件…

https://github.com/yeoman/generator-backbone/issues/268

なんか一部の処理がユーザの入力をすっ飛ばしているように見える. そして全ての生成ディレクトリ/ファイルがtest/ディレクトリ下に投入されていく.

でも

yukaary$yo backbone:view myview

とかするとなぜかappディレクトリが正しい位置にできたりして\(^0^)/状態…

一応対策でtest下に誤って配置されたと思われるファイル/ディレクトリを元の位置に戻してあげたら動いていはいるみたい.

使い勝手の学習

なんとか動くようにした(テストが動かなさそうだけど)ので使い勝手を確認していく.

yukaary$ yo backbone:router <name>
yukaary$ yo backbone:view <name>
yukaary$ yo backbone:collection <name>
yukaary$ yo backbone:model <name>

上のコマンドでBackboneの構成要素を適切な位置に追加していくことができる.

順番的には

  • router
  • view
  • collection, model

だろうか.

ただ、追加しただけでは利用可能にならないのでmainルーチン的なcoffeeファイルに追加した要素を追記していかなければならない等、微妙に使い勝手が悪い. そういうものなのかな?

  • router -> app/scripts/main.coffee
  • view -> 上で追加したrouter(app/scripts/routes/main.coffeeとか)

参考URl

http://albatrosary.hateblo.jp/entry/2014/02/05/172603

1 comment:

  1. Just as with each alternate watches, it is possible to purchase maintenance and even frequent support from this chronograph around the globe. That is the collectors item and even advice on it has the surgical procedure and thoughtful overhaul exists internationally http://www.replicabestsale.co.uk. In case you opt to, a eatches can certainly decrease as well, the following low-cost Xmas Treat is a fantastic suggestion for anybody which will is in love with looks after. Even if a lot of these running watches tend to be simple normally fabricated using of this basic brand models, they may be as a result the exact same with them this possibly even advisors can be can not say to them separate. Any Wristwatches really are for prime quality and therefore are built making use of long-lasting s / s. Many people come into play a competitive dark colored color selection detailed with a wristwatch pendant this is made of crocodile synthetic leather.

    ReplyDelete