JSFiddle - React, Tailwind, and code Playground

by Josh Pullen

JavaScript

const parser = new DOMParser();
const htmlDoc = parser.parseFromString(`<p>Hello, world!</p>test`, 'text/html');

let result = [];

console.log(htmlDoc.body);