text: var Nightmare = require("nightmare");
  
  var nightmare = Nightmare({ show: true });
  
  nightmare
    .goto("https://duckduckgo.com")
    .type("#search_form_input_homepage", "github nightmare")
    .click("#search_button_homepage")
    .wait("#links a")
    .evaluate(function() {
      return document.querySelector("#links a").href;
    })
    //.end()
    .then(function(result) {
      console.log(`Found some shit: ${result}`);
    })
    .catch(function(error) {
      console.error("Search failed:", error);
    });
  