Starting with Backbone LayoutManager

I was planing to use Backbone for my next project. Because it was a large application, I did start looking into the Backbone frameworks out there.
I took a look at Thorax.js, Marionette.js and LayoutManager.

Choosing LayoutManager

I decided to go with LayoutManager. One day, maybe I will write something more about the other ones because they are good and interesting frameworks. But in the end, I chosen LayoutManager because it is simple. I has all the things I needed and nothing more.
LayoutManager is created by Tim Branyen and you can find source code on Github. One of the things that convinced me to use LayoutManager is clean and well made wiki page. Everything seems to be covered there. But that is where my troubles started.

Video Tutorial

I wanted to save myself some time and watch a screen-cast instead of reading, so that I can dive right into it. Everything was nicely explained, but there was no source code of the example covered in screen-cast.
No problem, I thought, I will just follow the video and code along. I replicated all the files, but it was not working. The example was using Twitter API to fetch some data. The request was to the old and not supported version of Twitter API. Also some of the LayoutManager functions were returning errors. That is when I noticed - the video is two years old!

boilerplate-handlebars-layoutmanager

After realizing my mistake I went back to the documentation. There was the link to example with LayoutManager with Handlebars. This kind of integration was covered in the screen-cast, so I thought it will be perfect. The seed project was based on Backbone Boilerplate project, so it took me while to familiarize myself with the concept. After installing few node modules and bower components I was ready to start. Kind of... I understood the structure of the app thank to the post author refereed to in the video, but I wanted some app example I could play with.

The Thing I Was Looking For

I went back to the documentation of the core Boilerplate project, thinking that I will start from there and later add the LayoutManager to the project. I followed link to their example app, which is github-viewer. Turns out it uses the LayoutManager!
I found what I wanted. The app example is very well-structured and I think a perfect place to start hacking with LayoutManager. My tip for anyone that wants to use this framework is to start there.

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請結(jié)合常識與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

  • **2014真題Directions:Read the following text. Choose the be...
    又是夜半驚坐起閱讀 11,102評論 0 23
  • 其實(shí)每天都在效率手冊規(guī)劃一天的工作,但是確實(shí)很少回頭去回顧昨天過的效果如何。首次接觸晨間日記,一開始糾結(jié)于形式與模...
    海盜樹閱讀 185評論 2 0
  • 這一向,雨水連連。北方、長江中下游、閩浙川已出現(xiàn)特大險(xiǎn)情…… 令人擔(dān)心的是:平江也斷斷續(xù)續(xù)在迎接著一輪輪雨...
    天河水響閱讀 631評論 0 15
  • 書摘: 1.溝通最大的問題就是“已經(jīng)做好了”的錯(cuò)覺?!獑讨?蕭伯納 2.帕金森法則 3.生活中很多東西比金錢重要...
    咖啡不加糖和奶閱讀 218評論 0 0
  • 官網(wǎng) - 新手教程 - 操作說明為方便自己查看,Copy一份在此
    peony007閱讀 1,287評論 0 1

友情鏈接更多精彩內(nèi)容