Ok so first the likeable package needs a child of BaseModel from socialize:base-model to add it’s functionality to. As an example we can use a book for our model.
//I'll assume you know how to import what you need here :-)
//Let's create our model
let Book = BaseModel.extendAndSetupCollection("books");
//add a schema for security's sake
Book.appendSchema({
title:{
type:String
}
});
//this adds our liking functionality
LikeableModel.makeLikeable(Book, "book");
From there create some books that users can like
new Book({
title:'Moby Dick'
}).save();
new Book({
title: 'JavaScript: The good parts'
}).save();
Now that you’ve got some books, users can like them.
let book = Meteor.books.findOne();
book.like();
As a note this API will be changing in the near future when an update to the Socialize package set is released.