What is thee difference between appendChid() & append in js | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What is thee difference between appendChid() & append in js

26th Jan 2020, 6:28 AM
🇧🇩Muhammad iAR HOSSAIN🇧🇩
🇧🇩Muhammad iAR HOSSAIN🇧🇩 - avatar
3 Answers
+ 1
append is a jQuery method to append some content or HTML to an element. ::-> $('#example').append('Some text or HTML'); appendChild is a pure DOM method for adding a child element. ::-> document.getElementById('example'); If you're using jQuery library on your project, you'll be safe always using append when adding elements to the page.
26th Jan 2020, 6:39 AM
Prathvi
Prathvi - avatar
+ 1
🇧🇩EkmuthoSopno🇧🇩 mark this question as solved What is thee difference between appendChid() & append in js. [solved]
26th Jan 2020, 2:56 PM
🇮🇳Vivek🇮🇳
🇮🇳Vivek🇮🇳 - avatar
0
Thanks for your kind information.
26th Jan 2020, 2:11 PM
🇧🇩Muhammad iAR HOSSAIN🇧🇩
🇧🇩Muhammad iAR HOSSAIN🇧🇩 - avatar