I am working on a HTML5 project. I have created a rectangle using ctx.strokeRect(x,y,width,height). Also also filling text using ctx.fillText(textValue,x,y).But text floating outside the boundary. i want to keep all the text within the rectangle boundary using javascript as happen in TextArea (i.e. when we resize textarea then text wraps inside boundary)
Thanks in advance.