JSFiddle - React, Tailwind, and code Playground

by Emily Humphrey

JavaScript

var obj = {
	data: {
  	message: "hello",
    message2: "world!"
  },
	init: function(){
  	var parent = this;
    var data = this.data;
    
    data.saidHello = false;
    
    alert(data.message)
    
    setTimeout(function(){
    	alert(data.message2)
    });
    
    data.saidHello = true;
  }

}

obj.init();