I need help. I am working on a text editor for mobile and its a hybrid app, so its made with web technology. Everything is fine and all until I want to make a button that bolds future text, kind of like in Word. But I can only find one that makes everytext in the text area bold. This is not what I want. I cant find any help on how to do this in Javascript/Jquery on the internet.
This is what I have with jquery and jquery mobile:
$("#bold").on("tap",function(){
$(".editor").toggleClass("bold");
});
It makes every text in the editor bold. I want to make only future text bold.
Can someone help me?
Thank you