append an element to a container, why this selector?

append an element to a container, why this selector?

I am testing a js that allows adding texts to a container and then animates it through greensock.

Looks like the creation of every new text is made through


var txt = "Hello World!";
var ele = "#canvas";
var i = 8;
var particle = $("<div />", {id:"particle"+i}).addClass("particle").text(txt).appendTo(ele) ;
spawn(particle); // this function animates the just-created particle element (the text Hello World!) inside #canvas

But, what is code in line 4 doing? Apparently it creates the new element, but I can't see it

$("<div />", {id:"particle"+i}).addClass("particle").text(txt).appendTo(ele) 

thanks