meteor
  • famo.us
  • 2015-04-03 14 views 0 likes 
    0

    我想在沒有任何成功的情況下使用Meteor和Famo.us在網格中顯示一些曲面。在本地運行項目後,瀏覽器顯示空白屏幕。作爲參考,我在看這個例子:https://famous-views.meteor.com/views/GridLayout使用famo.us和流星在網格中顯示曲面的麻煩

    HTML

    <template name="gridTemplate"> 
        {{#GridLayout size='[undefined,undefined]' dimension='[3,3]'}} 
         {{#famousEach items}} 
          {{>ContainerSurface template='gridItem' }} 
         {{/famousEach}} 
        {{/GridLayout}} 
    </template> 
    
    
    <template name="gridItem"> 
        {{#Surface size='[undefined,undefined]'}} 
        <img src="/img/thumbnail.png"> 
        {{/Surface}} 
    
    </template> 
    

    的Javascript

    FView.ready(function(require) { 
        FView.registerView('GridLayout', famous.views.GridLayout); 
    }); 
    
    
    var items = [{ 
        name:"adfadf" 
        }, 
        { 
        name:"adfadf" 
        }, 
        { 
        name:"adfadf" 
        }, 
        { 
        name:"adfadf" 
    }]; 
    
    
    Template.gridTemplate.helpers({ 
        items:function() 
        { 
         return items; 
        } 
    }); 
    

    回答

    1

    我有同樣的錯誤,現在發現,遺憾的是目前流星的着名觀點已被棄用,以支持新版本,該版本與新發布的famo.us 0.5一起使用。和表面不再工作。

    您可以訪問https://github.com/gadicc/meteor-famous-views以瞭解更多關於它的信息,但現在的着名視圖幫助現在很難,因爲所有討論基本上都是針對新版本的。

    讓我知道你想出了什麼,到目前爲止我正在測試它自己。

    相關問題