Simple ES6 Promise

by j0b02py

Babel + JSX

const delay = () => {
  // Return a promise here with the signature function(resolve, reject)
  // Make this promise resolve with the text "Success!" after 2 seconds
  // If your implementation is correct, you should now see an alert when you run the code!
  
  // ADD YOUR CODE HERE
  
  // Hint: you will need "new Promise", "setTimeout", and "resolve"
};

delay().then((response) => {
	alert(response);
});