JSFiddle - React, Tailwind, and code Playground

by Carlos Medina

HTML

<div id="message">

</div>

JavaScript

var msg = document.getElementById("message");


//set default values to a person
var name = "No Name";
var birthMonth = "No Month";
var profession = "Nobody";

    //construction of the display function
        msg.innerHTML += "<center><p>" + name + " " + "was born on " + birthMonth + " and they are a " + profession + ". "

                //Month comparisons
                if (birthMonth=="April"){
                    msg.innerHTML += "They are meh because they were born in April.(eww)"
                }
                else if (birthMonth=="January"){
                    msg.innerHTML += "They are the best because they were born in the <strong>best month!</strong>"
                }
                else {
                    msg.innerHTML += "They are okay, at best."
                }
        //close paragraph tag       
        msg.innerHTML += "<hr></p></center>"