Skip to content

baysao/riot-template-helper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lets you easily include Riot components in Meteor templates. Pass the component class through the component argument.

Demo

Code

Examples: Your riotjs tag component

<todo>
  <h3>{ opts.title }</h3>
  <h3>{ opts.books }</h3>
</todo>
<template name="Home">
 {{#if Template.subscriptionsReady}}
  <div>
      {{> Riot component="todo" title="Hello papa" books=books}}
    </div>
  {{else}}
    <div class="loading">Loading ... </div>
  {{/if}}
</template>
Template['Home'].rendered = function(){
    var instance = this;
  instance.subscribe('books');
  
}
Template['Home'].helpers({
  books: function(){
    return 'books';
  }
})

About

Render your Riotjs template inside Blaze template

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published