選択できるのは25トピックまでです。
トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。
25 行
544 B
25 行
544 B
import { Template } from 'meteor/templating';
|
|
import { ReactiveVar } from 'meteor/reactive-var';
|
|
|
|
import "/lib/MyRes"
|
|
|
|
import './mainLayout.html';
|
|
import './templates/main_item'
|
|
import '/lib/router'
|
|
import './templates/user_page'
|
|
|
|
Template.hello.onCreated(function helloOnCreated() {
|
|
this.counter = new ReactiveVar(0);
|
|
});
|
|
|
|
Template.hello.helpers({
|
|
counter() {
|
|
return Template.instance().counter.get();
|
|
},
|
|
});
|
|
|
|
Template.hello.events({
|
|
'click button'(event, instance) {
|
|
instance.counter.set(instance.counter.get() + 1);
|
|
},
|
|
});
|
|
|