Appending to specific element append text only

I have prepended one div inside some div with many others:

<div class="content">

I added <div>ddd</div> before sss with:


And when I want to append some new element to new prepended div it add's it as text:


If I remove [0] it works but it appends to all divs, I need that [0] to find first div.

To get the first element (that is still a jquery object) you can use .first():


Note that I also wrapped the <p> with $(...) to make it a valid html element (and not text).