@visualdenniss
Posted
Good job on completing the challenge and implementing the logic! Overall it works, but there could be some improvement. To answer your question:
you can add external js file to your html by adding before </body>.
I'd also say try to avoid having the result in a new page like so: newWindow.document.write("<h1>Thank you for your rating!</h1>"); newWindow.document.write("<p>" + selectedText + "</p>");
But instead try to update the DOM by rendering new state of values. e.g. you can use Element.innerHTML = "..." https://developer.mozilla.org/en-US/docs/Web/API/Element/innerHTML for that etc.
Hope this was helpful!