there's a JS function called set like that can help you, you might want to try to mix CSOm and JSOM to create the functionality you want
you only need 4 parameters
the clientcontext (which is loaded for the site that contains the list)
the Value =True to like/False to unlike
then you can execute your queryasync and switch the label text to like/unlike depending the like status.
you'll still need to query somehow the item's likecount field to check if the users has liked the item before adding the like/unlike button