Check out example codes for "jquery select outer html". It will help you in understanding the concepts better.
Code Example 1
var outer_element_html = $('jQuerySelector')[0].outerHTML ;
console.log(outer_element_html);
Learn ReactJs, React Native from akashmittal.com