Replace text inside this paragraph on form submit.
Attach an event handler on the form submit action. On form submit replace contents of
"p#receive-input
" with the value of "input#type-input
"-input and
reset value of "input#type-input
" to empty string. Prevent default action for
submit event.
The following can be helpful:
Document.getElementById()
,
Document.querySelector()
,
EventTarget.addEventListener()
,
Event.preventDefault()
and
HTMLElement.innerText