Reference createP()

createP()

Creates a paragraph element.

elements are commonly used for paragraph-length text.

The parameter html is optional. It accepts a string that sets the inner HTML of the new

.

Examples

Syntax

createP([html])

Parameters

html
String:

inner HTML for the new <p></p> element.

Returns

p5.Element: new p5.Element object.
This page is generated from the comments in src/dom/dom.js . Please feel free to edit it and submit a pull request!

Related References