如何在点击链接时在流星中显示图标

时间:2022-06-04 19:41:34

How to set viewed icon on click of a link in meteor. I have a list jobs page and when user clicks on one job it is going to the description page and what I want is display an icon on the post which tells user that he or she viewed the post.

如何在点击流星链接时设置查看的图标。我有一个列表作业页面,当用户点击一个作业时,它将进入描述页面,我想要的是在帖子上显示一个图标,告诉用户他或她查看了帖子。

1 个解决方案

#1


0  

Try to use this:

试着用这个:

Template.yourTemplate.events({
    'click .viewed'(event, instance) {
       event.preventDefault();
       instance.$('youriconReference').show();
    },
});

#1


0  

Try to use this:

试着用这个:

Template.yourTemplate.events({
    'click .viewed'(event, instance) {
       event.preventDefault();
       instance.$('youriconReference').show();
    },
});