Create <p> tags quickly

This commit is contained in:
Pierre 2018-05-23 21:14:38 +02:00
parent 9a7c3245c4
commit 91f8edd2de

View File

@ -460,6 +460,21 @@ function add_space(target){
} }
/**
* Create and append a new paragraph
*
* @param {HTMLElement} target The target for the new paragraph
* @param {String} content The new content for the paragraph
* @returns {HTMLElement} Generated element
*/
function add_p(target, content){
return createElem2({
appendTo: target,
type: "p",
innerHTML: content
});
}
/** /**
* Get the current absolute position bottom of the screen * Get the current absolute position bottom of the screen
* *