创建一个 <button></button> 元素。
第一个参数,label,是一个字符串,设置按钮上显示的标签。
第二个参数,value,是可选的。它是一个字符串,设置按钮的值。更多详情请参见 MDN。
示例
语法
createButton(label, [value])
参数
label
字符串:
按钮上显示的标签。
value
字符串:
按钮的值。
返回值
p5.Element: 新的 p5.Element 对象。
This page is generated from the comments in src/dom/dom.js . Please feel free to edit it and submit a pull request!